🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: bit.listserv.asm370
Article #1655

Re: Ampersand in a DC statement

#1655
From: Tony Fitzgerald (506) 453-4573
Date: Wed, 20 May 1992 17:28
38 lines
2082 bytes
On  Wed, 20 May 92 12:25:13 ADT  "John R. Grout" <grout@CSRD.UIUC.EDU>
writes:
> Try doubling the ampersand (e.g., DC CL4'C&&T ').

This is true and will fix the original problem, however, deserves an
aside (well at least I think it deserves one :-) about the situation
when an ampersand is required in conditional assembly.  Let's assume
that you want to check whether a SETC expression contains a single
ampersand,  you have to do something like the following:

         AIF   ('expression'(&CTR,1) EQ '&&'(1,1)).seqsym

It is necessary to use a doubled ampersand then take a substr in order
to have only one of them because the SETC string will carry them as
a pair of ampersands.  Try the following at home:

         MACRO
         TEST
         LCLA  &L1,&L2
         LCLC  &A,&B
&A       SETC  '&&'
&B       SETC  '&A'(1,1)
&L1      SETA  K'&A
&L2      SETA  K'&B
         MNOTE *,'LENGTH OF &&A="&A" IS &L1, AND OF &&B="&B" IS &L2'
         MEND
         TEST
         END

Trivia question: About which ampersamd is IEV127 complaining?

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-  J. Anthony Fitzgerald                  Phone:     (506) 453-4573
   Computing Services                     NetNorth:  JAF@UNB.ca
   The University of New Brunswick              or   JAF@UNB
   PO Box 4400
   Fredericton, N.B.  Canada
   E3B 5A3
Technical Details
Message-ID: <ID9102.D920520.T142859.JAF@UNB.CA>
Path: arc1-ca.pugleaf.net!sparky!uunet!paladin.american.edu!auvm!UNB.CA!JAF

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fcdcb,d975e53c774a70d6
X-Google-Attributes: gidfcdcb,public
X-Google-ArrivalTime: 1992-05-20 08:04:32 PST
Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU
Path: arc1-ca.pugleaf.net!sparky!uunet!paladin.american.edu!auvm!UNB.CA!JAF
Message-ID: <ID9102.D920520.T142859.JAF@UNB.CA>
Newsgroups: bit.listserv.asm370
Date:         Wed, 20 May 1992 14:28:59 ADT
Sender:       IBM 370 Assembly Programming Discussion List <ASM370@UGA.BITNET>
From:         "Tony Fitzgerald (506) 453-4573" <JAF@UNB.CA>
Subject:      Re: Ampersand in a DC statement
In-Reply-To:  Message of Wed, 20 May 92 12:25:13 ADT from <grout@CSRD.UIUC.EDU>
Lines: 38