Jonathan,
Thanks for the response. I was thinking that there should be a way such as
specifying two USINGs to accomplish what I want (rather than physically
re-basing by +2). However, I got the idea that it would require another
register to be dedicated to that use. So... Would I need a second
register for what you suggested? Or is there a way to just have two USINGs
for the same DSECT where the two USINGs are offset from each other by 2
bytes?
The legacy use needs a zero-based reference.
The scripting use needs a reference two bytes before that.
Otherwise, the negative equates are the only way I know to accomplish this.
TXTINPT DSECT INPUT STRING PARAMETER
TXTSREQU DS CL1 SCRIPTING REQUEST CODE <===
need a base here
TXTSRETN DS CL1 SCRIPTING RETURN CODE
TXTSSTRL DS H SCRIPTING INPUT/OUTPUT STRING LENGTH
TXTSSTRG DS 256CL1 SCRIPTING INPUT/OUTPUT STRING
ORG TXTINPT
STR_REQU EQU *-2,1,C'C' DYNAMIC REFERENCE TO STRING REQUEST
STR_RETN EQU *-1,1,C'C' DYNAMIC REFERENCE TO STRING RETCODE
TXTSTRL DS H LEGACY INPUT/OUTPUT STRING LENGTH <==
and a base here
TXTSTRG DS 256CL1 LEGACY INPUT/OUTPUT STRING
ORG
Sincerely,
Dave Clark
On Tue, Feb 17, 2026 at 3:54 AM Jonathan Scott <
[email protected]> wrote:
> Note that USING does not have to be based on the start of a DSECT.
> Instead of using equates with negative offsets, you can use a DSECT which
> includes the prefix fields, but specify the first of the original fields on
> the USING statement to map those as before, with the prefix fields having
> negative offsets from the base register.
>
> Jonathan Scott
>