dollar signs in identifiers (was: warning: '/*' within comment)
Karl Heuer
karl at haddock.ima.isc.com
Thu Jun 14 12:50:19 AEST 1990
In article <13082 at smoke.BRL.MIL> gwyn at smoke.BRL.MIL (Doug Gwyn) writes:
>In article <16490021 at hpcllca.HP.COM> walter at hpcllca.HP.COM (Walter Murray) writes:
>>I don't see how this can be a strictly conforming program. [`$' need not be
>>a member of the source character set.]
I'll reluctantly concede that point. (But see below.)
>Quite right; a strictly conforming program cannot use '$' in identifiers.
Not relevant; the program in question wasn't using it in an identifier. That
was, in fact, the point: the Standard requires that any implementation in
which `$' is in the source character set (in practice, any implementation in
the ASCII-or-superset world) *must* accept the program and generate a result
contrary to what is produced by the traditional DEC or Apollo compilers.
>I stopped using ` characters in comments when I realized that they could
>impair portability.
I figure it's a Quality of Implementation issue. An implementation that
disallows "`" in a comment probably won't survive long in a free market.
(And if some of the characters in my source file cause a change in shift
state when interpreted in the implementation's character set, then the vendor
had better supply a translator that maps my character set into his.)
Karl W. Z. Heuer (karl at ima.ima.isc.com or harvard!ima!karl), The Walking Lint
More information about the Comp.std.c
mailing list