www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - DMD commandline bug

reply Hauke Duden <H.NS.Duden gmx.net> writes:
The following commandline is not accepted by DMD

dmd -version=_UNICHAR_FAST_ unichar.d

The error message is:
"Error: unrecognized switch '-version=_UNICHAR_FAST_'"

But the commandline help lists the following switch:
"-version=ident compile in version code identified by ident"

So either the switch is not documented correctly or it is not parsed right.

Hauke
Jun 13 2004
parent reply Mike Swieton <mike swieton.net> writes:
On Sun, 13 Jun 2004 13:37:59 +0200, Hauke Duden wrote:
 The following commandline is not accepted by DMD
 
 dmd -version=_UNICHAR_FAST_ unichar.d
For some reason, the leading underscore is throwing it off. Otherwise, over here the behavior is reasonable. Mike Swieton __ You can have peace. Or you can have freedom. Don't ever count on having both at once. - Lazarus Long (Robert A. Heinlein)
Jun 13 2004
parent reply Hauke Duden <H.NS.Duden gmx.net> writes:
Mike Swieton wrote:

 On Sun, 13 Jun 2004 13:37:59 +0200, Hauke Duden wrote:
 
The following commandline is not accepted by DMD

dmd -version=_UNICHAR_FAST_ unichar.d
For some reason, the leading underscore is throwing it off. Otherwise, over here the behavior is reasonable.
Ah. You're right, it does work without the underscore. Thanks. So it really seems to be a bug in the commandline parsing. Hauke
Jun 13 2004
parent reply "Walter" <newshound digitalmars.com> writes:
"Hauke Duden" <H.NS.Duden gmx.net> wrote in message
news:cai460$j5t$1 digitaldaemon.com...
 Mike Swieton wrote:

 On Sun, 13 Jun 2004 13:37:59 +0200, Hauke Duden wrote:

The following commandline is not accepted by DMD

dmd -version=_UNICHAR_FAST_ unichar.d
For some reason, the leading underscore is throwing it off. Otherwise,
over
 here the behavior is reasonable.
Ah. You're right, it does work without the underscore. Thanks. So it really seems to be a bug in the commandline parsing.
True, but also leading _ on identifiers are reserved in D.
Jun 13 2004
parent "Vathix" <vathixSpamFix dprogramming.com> writes:
 True, but also leading _ on identifiers are reserved in D.
"Identifiers starting with __ (two underscores) are reserved." A single leading underscore should work :P
Jun 13 2004