At 6:54 PM -0800 11/8/04, Jeff Clites wrote:
But the part I was really wondering about is the "a + b". This is what pie-thon.pl produces for that (you can just run it on the code fragment "a + b"--it doesn't matter the context):

        $P1 = new PerlInt               # BINARY_ADD
        $P1 = a + b

corresponding pasm:

        find_global P18, "a"
        find_global P17, "b"
        new P16, 32      # .PerlInt
        add P16, P18, P17

That's what worries me, and what prompted the question. You don't know at compile-time that the return type should be a PerlInt. It could be anything--it's really up to "a". This is regarding my concern that the p_p_p ops aren't very useful (in Python at least), and I can't figure out what we should be using instead.

Right. PerlInt is wrong. The destination type for the intermediates should be Undef, which changes itself on assignment to the proper type.
--
Dan


--------------------------------------it's like this-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to