[Issue 15277] unable to compile .d flies with numbers at the beginning of the name

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Mon Nov 2 14:24:15 PST 2015


https://issues.dlang.org/show_bug.cgi?id=15277

ag0aep6g at gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |ag0aep6g at gmail.com
         Resolution|---                         |INVALID

--- Comment #1 from ag0aep6g at gmail.com ---
As far as I can see, everything works as expected here.

dmd doesn't mind "1.d" as a file name.

What's rejected is "1" as a module name. The module name is taken from the file
name when there is no module declaration (`module foo;`). Module names are
specified to be identifiers [1]. Identifiers are specified not to start with
digits [2].

Closing as invalid. Please reopen if I'm missing something here.

[1] http://dlang.org/module.html#ModuleName
[2] http://dlang.org/lex.html#IdentifierStart

--


More information about the Digitalmars-d-bugs mailing list