David Crayford wrote:

On 10/08/2018 7:34 PM, Peter Relson wrote:

I have no idea why the health checker header files in
SYS1.SIEAHDR.H(HZS*) chose to use them.

Because no one was willing to take a stand that everyone has a system like
yours that can handle the braces, at the expense of someone who did not.


You make a good point Peter and I certainly don't mean any disrespect to the original authors of those header files. It's just IMO trigraphs are worse then using a codepage such as 1047 which is the ubiquitous C codepage on z/OS.

Nevertheless, it seems unlikely that there will be additional use of the

#pragma codepage presents its on set of problems.

Consider, for instance, you move the source into a Git repository
on a remote (and ASCII) system.   And, if you have a cross-compiler,
might consider compiling on that remote system.

Now, your source claims to be in code-page 1047 - but it certainly isn't likely
to be so, since the move to the ASCII system rendered it in ASCII.

This means your cross-compiler has to quietly ignore the #pragma codepage
and hope that your transmission to the ASCII system did "the right thing."

Trigraphs are hideously ugly; but they did produce portable source files
that could be moved around and compiled.

As I mentioned in another post; C++17 removed support for Trigraphs
from their language definition.... so, they are generally going away...

    - Dave R. -


--
riv...@dignus.com                        Work: (919) 676-0847
Get your mainframe programming tools at http://www.dignus.com

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to