Suggest aesthetic way to Naming a module or a package with illegal lexical D lang keywords

BoQsc vaidas.boqsc at gmail.com
Sun Jun 16 11:27:52 UTC 2019


Do not ask why I want to do that, you can however suggest 
alternative variations.

As you all might know,

> 2. The Identifiers preceding the rightmost are the Packages 
> that the module is in. The packages correspond to directory 
> names in the source file path. Package and module names cannot 
> be Keywords.
https://dlang.org/spec/module.html#module_declaration

The D Spec literally says that we cannot use these words in the 
Module Names:
https://dlang.org/spec/lex.html#Keyword

Example, we can't Name Modules or Packages like that:

> module auto.alias.abstract;
> void main(){
>
>
>}




I would like to know if there is any way to make it possible to 
name Modules/Packages via preoccupied lexical words, or at least 
receive some suggestions on some aesthetic naming for a 
module/package that includes these lexical d words.


Examples:

> module dauto.dalias.dabstract;
> void main(){
>
>
>}

> module CustomAuto.CustomAlias.CustomAbstract;
> void main(){
>
>
>}



More information about the Digitalmars-d-learn mailing list