Fixed an issue when `build_unflags operation ignores a flag value // Resolve #4309

This commit is contained in:
Ivan Kravets
2022-06-17 14:25:39 +03:00
parent 5afa0a955e
commit db6b8a6dbc
2 changed files with 6 additions and 3 deletions
+3 -1
View File
@@ -258,7 +258,9 @@ def ProcessUnFlags(env, flags):
for current in env.get(key, []):
conditions = [
unflag == current,
isinstance(current, (tuple, list)) and unflag[0] == current[0],
not isinstance(unflag, (tuple, list))
and isinstance(current, (tuple, list))
and unflag == current[0],
]
if any(conditions):
env[key].remove(current)