Ticket #1886 (assigned bug)
set_string_native() not implemented in class 'TclString'
Reported by: | coke | Owned by: | whiteknight |
---|---|---|---|
Priority: | critical | Milestone: | |
Component: | none | Version: | master |
Severity: | fatal | Keywords: | |
Cc: | Language: | tcl | |
Patch status: | Platform: |
Description
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