I would like to do something like
`
dmd --buildversion=fooCollection{"a", "b", "c"} -run app.d

...

void bar()
{
    static foreach(i; fooCollection)
    {
        ...
    }
}
`

The idea being that bar can be packed in a library and the program that includes this library can decide what parameters will be added to foo whitout any runtime overhead and ugly looking syntax.

Is something simular possible?
If not, could I achieve thesame result by including a file `programsettings.d` with some compile time constants in there whitout my library depending on it?

Reply via email to