BTW, to reproduce, you can go pull source from:
https://github.com/pixie-lang/pixie

Then run ./make-with-jit

The build script assumes that above the pixie directory you have pypy
checkout in a directory named "pypy".


On Sat, Oct 18, 2014 at 5:11 PM, Timothy Baldridge <[email protected]>
wrote:

> What's also odd, is that there is something non-deterministic about these
> errors, sometimes I get the one error, but if I translate again (without
> changing any code) I'll get the other.
>
> On Sat, Oct 18, 2014 at 2:08 PM, Timothy Baldridge <[email protected]>
> wrote:
>
>> My interpreter is built using mostly unicode for symbols and strings, but
>> recently I've been getting some really weird translation errors. The first
>> is this: https://gist.github.com/halgari/0d57dd87434968561705
>>
>> I tracked this error down to being caused whenever I try an isinstance of
>> unicode like this:
>>
>> isinstance(x, unicode)
>>
>> This is really annoying as I'd love to have a single unified wrap
>> function:
>>
>>     @specialize.argtype(0)
>>     def wrap(x):
>>         if isinstance(x, int):
>>             return numbers.Integer(x)
>>         if isinstance(x, unicode):
>>             return String(x)
>>
>>
>> And as of this morning I started getting errors like this:
>>
>> [translation:ERROR] TyperError: don't know how to convert from
>> <UnicodeRepr * GcStruct rpy_unicode { hash, chars }> to <UniCharRepr
>> UniChar>
>> [translation:ERROR] .. (pixie.vm.reader:47)PromptReader.read
>> [translation:ERROR] .. block@82 with 1 exits
>> [translation:ERROR] .. v235 = simple_call(v234)
>>
>> What is a UniChar? My code only deals with unicode strings, so I'm not
>> sure what's happening here.
>>
>> Thanks for any help. I've had unicode working perfectly with my
>> interpreter for weeks, and suddenly in the past two days I've started
>> getting these errors.
>>
>> Timothy
>>
>
>
>
> --
> “One of the main causes of the fall of the Roman Empire was that–lacking
> zero–they had no way to indicate successful termination of their C
> programs.”
> (Robert Firth)
>



-- 
“One of the main causes of the fall of the Roman Empire was that–lacking
zero–they had no way to indicate successful termination of their C
programs.”
(Robert Firth)
_______________________________________________
pypy-dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-dev

Reply via email to