May 09, 2023 [Issue 23909] New: std.getopt stopOnFirstNonOption ignored with switches | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=23909 Issue ID: 23909 Summary: std.getopt stopOnFirstNonOption ignored with switches Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: regression Priority: P1 Component: phobos Assignee: nobody@puremagic.com Reporter: dlang-bugzilla@thecybershadow.net It tries to parse the switch (and throws "Can't parse string"), even though there is a non-option argument before it: /////////////////// test.d /////////////////// import std.getopt; void main() { string[] args = ["program", "dmd", "-de"]; bool doDownload; getopt(args, "d", &doDownload, config.stopOnFirstNonOption, ); } ////////////////////////////////////////////// Introduced in https://github.com/dlang/phobos/pull/1050 -- |
Copyright © 1999-2021 by the D Language Foundation