#1886: set_string_native() not implemented in class 'TclString'
--------------------+-------------------------------------------------------
 Reporter:  coke    |       Owner:        
     Type:  bug     |      Status:  new   
 Priority:  normal  |   Milestone:        
Component:  none    |     Version:  master
 Severity:  medium  |    Keywords:        
     Lang:  tcl     |       Patch:        
 Platform:          |  
--------------------+-------------------------------------------------------
 This error has cropped up in the last few months in partcl-nqp. (No
 changes in partcl, just upgrading parrot was sufficient to gen the error)

 In one case, there was a concat operation in our
 src/Partcl/commands/time.pm ; prefixing the first element with a ~ avoided
 the error. (but should have been unnecessary.)

 There is another location where this error occurs, triggered by the
 following tcl:

 {{{
 $ cat error.tcl
 for {set i 0} {$i < 2} {set i [expr $i+1]} {puts $i}
 $ ./partcl error.tcl
 0
 1
 set_string_native() not implemented in class 'TclString'
     while executing
 eval
     (file "<unknown file>" line 7)
 for
     (file "<unknown file>" line 12)
 HLL::Compiler::eval
     (file "<unknown file>" line 151)
 PCT::HLLCompiler::evalfiles
     (file "<unknown file>" <unknown line>)
 PCT::HLLCompiler::command_line
     (file "<unknown file>" <unknown line>)
 main
     (file "<unknown file>" line 1)
 }}}

 In eval (src/Partcl/commands/eval.pm) the error is occurring when invoking
 the sub generated by:

 {{{
 my &sub := Partcl::Compiler.compile($code);
 &sub(); #BOOM
 }}}

 In any case, TclString should in fact have a set_string_native, inherited
 from its parent class of String; it's declared in an nqp file as:

 {{{
 class TclString is String
 }}}

-- 
Ticket URL: <https://trac.parrot.org/parrot/ticket/1886>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets

Reply via email to