On Tue, Sep 2, 2008 at 12:43 PM, Allison Randal <[EMAIL PROTECTED]> wrote:

> Klaas-Jan Stol wrote:
>
>>
>> This must make the following syntax rule illegal:
>>
>>  target = null
>>
>> because if "null" is declared as a .local, you can't know whether you want
>> to nullify target, or want to set target's value to that of the .local
>> variable "null".
>>
>> I take it this is no problem; just stick to
>>
>>  null target
>>
>> if you actually want to set target to 0/null.
>>
>
> Yes, that's reasonable. The syntactic sugar was confusing in that case
> anyway. (Seemed like you were assigning a null value to the destination
> register, rather than nullifying the PMC in the destination register.)
>
> This belongs in a general category of opcodes where the standard
> transformation of "call the opcode with the first argument stuck before an
> '=' sign" doesn't really make sense.
>
> Allison
>

the problem seems to be a bit bigger than I had foreseen. The issue is that
ops with the first operand marked as 'OUT' may be rewritten as:
target = op [operand [, operand]*]?

However, consider the following:

.local pmc getstdin

$P0 = getstdin

How should this be resolved? is the opcode 'getstdin' meant here, or is it
the value of the .local getstdin. This problem occurrs with all ops, not
only with single-operand ops.

kjs

Reply via email to