digitalmars.D.bugs - [Issue 17775] New: dmd master __VERSION__ should match the major
- via Digitalmars-d-bugs (35/35) Aug 23 2017 https://issues.dlang.org/show_bug.cgi?id=17775
https://issues.dlang.org/show_bug.cgi?id=17775 Issue ID: 17775 Summary: dmd master __VERSION__ should match the major release that it will be for Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: dmd Assignee: nobody puremagic.com Reporter: issues.dlang jmdavisProg.com Right now, it seems that the way that dmd version number is handled is that it matches the current major release and gets bumped when another major release is made. So, if 2.075 is the current major release, then dmd --version with dmd master prints something like DMD64 D Compiler DMD64 D Compiler v2.075.0-336-g12fa5f06c and __VERSION__ is 2075. The main problem that I see with this is that if a change is made in master, and a project wants to / needs to version code differently based on whether it's building with master or something older, there's no way to do it, because __VERSION__ is the same for both, whereas if master had the version number of the release that will come from it next rather than the release that came from it last, then no such problem exists. And since minor releases are released from the stable branch rather than master, having master be a higher version number than what the minor release will have shouldn't matter, and the higher version that master does have will match what the next major release is. So, it can just be bumped after the new branch for the next release is made rather than being bumped right before it's made, which seems to be how it works now. What we have right now seems to manage to make sure that the releases have the right version, but it doesn't play well at all for using __VERSION__ when you need to differentiate from master. --
Aug 23 2017