diff options
| author | Ulf Magnusson <ulfalizer@gmail.com> | 2018-10-08 23:49:30 +0200 |
|---|---|---|
| committer | Ulf Magnusson <ulfalizer@gmail.com> | 2018-10-08 23:49:30 +0200 |
| commit | d29fb1398c608f6923aacabfbf0baabdc900c249 (patch) | |
| tree | 72ee1d17796cf220cd07d614b6a13bb6b46eb508 | |
| parent | 8523423ca99c0f486a7c1e90801b1be14fdd1457 (diff) | |
Remove redundant elifs in expr_value()
Leftover from assigning a 'res' variable.
| -rw-r--r-- | kconfiglib.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/kconfiglib.py b/kconfiglib.py index ea212f5..8af1c29 100644 --- a/kconfiglib.py +++ b/kconfiglib.py @@ -5176,12 +5176,12 @@ def expr_value(expr): # parse as numbers comp = _strcmp(v1.str_value, v2.str_value) - if rel is EQUAL: return 2*(comp == 0) - elif rel is UNEQUAL: return 2*(comp != 0) - elif rel is LESS: return 2*(comp < 0) - elif rel is LESS_EQUAL: return 2*(comp <= 0) - elif rel is GREATER: return 2*(comp > 0) - elif rel is GREATER_EQUAL: return 2*(comp >= 0) + if rel is EQUAL: return 2*(comp == 0) + if rel is UNEQUAL: return 2*(comp != 0) + if rel is LESS: return 2*(comp < 0) + if rel is LESS_EQUAL: return 2*(comp <= 0) + if rel is GREATER: return 2*(comp > 0) + if rel is GREATER_EQUAL: return 2*(comp >= 0) _internal_error("Internal error while evaluating expression: " "unknown operation {}.".format(expr[0])) |
