Bug 13292 – DMD accepts both -m32 and -m64

Status
RESOLVED
Resolution
WONTFIX
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-08-14T06:18:28Z
Last change time
2020-04-28T23:49:56Z
Keywords
bootcamp, pull
Assigned to
No Owner
Creator
Maxim Fomin

Comments

Comment #0 by mxfomin — 2014-08-14T06:18:28Z
It seems that dmd silently accepts simultaneously -m32 and -m64 and generates code according to last option. void main() {} With -m32 -m64 it produces x64 and with -m64 -m32 it produces x86. It either should issue a warning or error.
Comment #1 by dlang-bot — 2020-04-25T15:43:21Z
@wolframw created dlang/dmd pull request #11058 "Fix Issue 13292 - DMD accepts both -m32 and -m64" fixing this issue: - Fix Issue 13292 - DMD accepts both -m32 and -m64 https://github.com/dlang/dmd/pull/11058
Comment #2 by pro.mathias.lang — 2020-04-28T23:49:56Z
As mentioned in the PR open by @woframw, this is actually not something we want. It's a common behavior of CLI to allow args to be overridden, and just take the last one into account. We have some switch that follow this behavior already (checkaction), and we rely on this behavior in our testsuite. Closing as WONTFIX.