Allow OPT to accept optional dashes before flags

This commit is contained in:
Rangi42
2025-08-06 10:19:01 -04:00
parent a4a830776b
commit f9a55bd5cd
3 changed files with 7 additions and 3 deletions

View File

@@ -53,6 +53,9 @@ void opt_W(char const *flag) {
}
void opt_Parse(char const *s) {
if (s[0] == '-') {
++s;
}
switch (s[0]) {
case 'b':
if (strlen(&s[1]) == 2) {