Specifying possible version statements for libraries and apps

Chris Piker chris at hoopjump.com
Fri Oct 8 22:10:44 UTC 2021


On Friday, 8 October 2021 at 17:01:47 UTC, WebFreak001 wrote:
> I was thinking about this because issues like this could be 
> avoided: https://github.com/das-developers/das2D/issues/2 (all 
> builtin versions would be included in the list by default, 
> could lint the list for not clashing the builtin versions)

Thanks for noticing that bug, and more importantly, filing an 
issue :-)

So until you pointed it out I didn't realize I was operating 
under the assumption that the [pre-defined version 
strings](https://dlang.org/spec/version.html#predefined-versions) 
were the only values understood by `version`, even though the top 
of the linked documentation page clearly states that, like a C 
macro, any version identifier string is acceptable.

I'm not sure how this could be addressed without introducing more 
restrictions then it's worth.  If I mistype the "_WIN32" macro in 
a C source file there's no way for the compiler to know what I 
meant, so I just accept that and move on.

This one is definitely more insidious though, since there's so 
few big-endian machines around for testing anymore.

Out of curiosity, what was the last version of dmd to even run on 
Solaris?


More information about the Digitalmars-d mailing list