In my test bed, I've switched tcl over to using unicode for most of its strings, so that the following tcl code:
puts "\u30b3\u30fc\u30d2\u30fc"
Generates the appropriate kana output.
However, this switchover exposed a problem with some parrot guts. While most of the tcl test suite works, the following PIR demonstrates the problem some of the remaining code is tripping over:
.sub main @MAIN
$P0 = new Integer
store_global "Foo", unicode:"Bar", $P0
print "ok 1\n"
.end
It generates the error:
unimplemented unicode
in file 'foo.pir' near line 3
The problem appears to be with using a unicode string as a hash key. After fighting with gdb for a while, I finally figured out this is due to the fact that charset/unicode.c is throwing an exception inside compute_hash.
Generating a ticket so I have somewhere to point when I make this a TODO test.
> .sub main @MAIN
> $P0 = new Integer
> store_global "Foo", unicode:"Bar", $P0
> print "ok 1\n"
> .end
> It generates the error:
> unimplemented unicode
Yep. charset/unicode.c:compute_hash() *was* unimplemented.
leo