On 5/16/2012 9:48 AM, John Ehrman wrote:
Macro
&Lab MVC2&Target,&Source
&Lab CLC 0(0,0),&Source X'D500 0000',S(&Source)
Org *-6 Back up to first byte of instruction
LA 0,&Target.(0) X'4100',S(&Target),S(&Source)
Org *-4 Back up to first byte of instruction
DC AL1(X'D2',L'&Source-1) First 2 bytes of instruction
Org *+4 Step to next instruction
MEnd
This is very similar to the macro we have of the same name. Only ours has an AIF
that tests the first character of &Target for '(' and takes a second path that
supports the following coding format:
MVC2 displacement(,reg),source_field
For example:
MVC2 0(,R14),_1.DSTDEST Set Character DEST data
Without that second path through the macro, the above code will fail with:
** ASMA173S Delimiter error, expected blank - (0)
--
Edward E Jaffe
Phoenix Software International, Inc
831 Parkview Drive North
El Segundo, CA 90245
310-338-0400 x318
[email protected]
http://www.phoenixsoftware.com/