Incremental improvement to parsing none for optional arguments

This commit is contained in:
Bruce Hill 2025-03-07 12:26:22 -05:00
parent 1c90901553
commit 3ea8540ec6

View File

@ -72,6 +72,9 @@ static bool parse_single_arg(const TypeInfo_t *info, char *arg, void *dest)
{
if (!arg) return false;
if (info->tag == OptionalInfo && streq(arg, "none"))
return true;
while (info->tag == OptionalInfo)
info = info->OptionalInfo.type;