All,

just tried it on z390. I get the following instruction:
           LA     0,=AL(3)(2)(1)
which assembles as 4101C1C8

where the literal ultimately assembles as AL(3)(2)
I.e. the trailing (1) has been trimmed off and the generated value is
X'000002' as expected.

This matches HLASM behaviour exactly. Again, I am surprised by the
robustness of the z390 code.
Chapeau for Don Higgins (creator of the z390 assembler emulator)

And thanks to John Ehrman for testing our wit :-)

Kind regards,
Abe Kornelis
(maintenance coordinator for z390)
====




John Ehrman schreef op 26-3-2015 om 23:07:
> Steve Smith asked for the answer to my quiz question of March 23:
>
>> While we're having fun: under what circumstances is the character 
> sequence
>>         (4)(3)(2)(1)
>>
>> legal as part of a machine instruction operand, not part of a quoted
>> string, not part of a macro operand, and not part of a SETC statement?
> And no, it's not an "April-Fool" question. 
> Here's the answer:
>         USING  *,12
> &V(4)   SETC   'L'
>         LA     0,=A&V(4)(3)(2)(1)
>         END
>
> Try assembling it!  (And no, it wasn't my idea originally.)
>
> Regards... John 
>

Reply via email to