On Mon, Jun 27, 2016 at 11:14 AM, Martin Truebner <[email protected]>
wrote:

> John,
>
> I use
>
> STRING_with_term   DC C'this is a string',X'0'
>
> it has the wrong length attribute (one less) but is easier to decipher
> than a macro.
>

​I was too. But the wrong length just didn't sit well with me. That's where
I defined &NULL as a SETC symbol with a BYTE(00) and did DC C'this is a
string&NULL'. I'm just looking for alternatives. What I'd really like for
HLASM to have a CZ operand which automatically added the x'00' to the end,
padded short strings with all x'00', and issued an error if you used a
length which was too small to include the ending x'00'

E.g. DC CZ'ABC' would be of length 4, encoded as C1C2C300. DC CZL3'ABC'
would get at least a warning and truncate like C'...' does. DC CZL3'A'
would encode as C10000.

I'm not putting in a RFE because I doubt that it is that useful to others.
Also, the time & talent could probably be better spend in other areas of
improvement.



>
> Martin


-- 
"Pessimism is a admirable quality in an engineer. Pessimistic people check
their work three times, because they're sure that something won't be right.
Optimistic people check once, trust in Solis-de to keep the ship safe, then
blow everyone up."
"I think you're mistaking the word optimistic for inept."
"They've got a similar ring to my ear."

>From "Star Nomad" by Lindsay Buroker:

Maranatha! <><
John McKown

Reply via email to