[Issue 16539] std.getopt should invoke callbacks in the order given on the command line
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Mon Dec 12 17:58:19 PST 2016
https://issues.dlang.org/show_bug.cgi?id=16539
--- Comment #2 from Jon Degenhardt <jrdemail2000-dlang at yahoo.com> ---
I looked into adding support for processing arguments in command line
(run-time) order. However, processing arguments in the compile-time specified
order (getopt function call order) appears fairly baked into the design. My
personal assessment is that it would be a fair undertaking. If this such an
effort was done, it might be better to do it as part of a new version of getopt
that was improved in other dimensions as well.
For my own code I created a wrapper over getopt that processes arguments in
command line order. It works fine most of the time, but is more brittle/hacky
than appropriate for phobos. The wrapper is here:
https://github.com/eBay/tsv-utils-dlang/blob/master/common/src/getopt_inorder.d
--
More information about the Digitalmars-d-bugs
mailing list