Bug 19362 – std.getopt.config: change type to disallow or support bitwise operands

Status
NEW
Severity
enhancement
Priority
P4
Component
phobos
Product
D
Version
D2
Platform
x86_64
OS
Linux
Creation time
2018-11-03T18:37:33Z
Last change time
2024-12-01T16:34:27Z
Assigned to
No Owner
Creator
Neia Neutuladh
Moved to GitHub: phobos#10357 →

Comments

Comment #0 by dhasenan — 2018-11-03T18:37:33Z
Test case: --- unittest { import std.getopt; auto args = ["exe", "-h"]; int intFlag = 5; auto result = getopt(args, config.caseSensitive | config.bundling, "H", &intFlag); assert(intFlag == 5); assert(result.helpWanted); } --- It's normal with logically composable enums to be able to or them together. This doesn't work for std.getopt. If it compiles, it should do the right thing.
Comment #1 by robert.schadek — 2024-12-01T16:34:27Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/phobos/issues/10357 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB