From e532c2a7d34cbde528c0c91c83594a0694c9256f Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Fri, 22 Sep 2017 07:56:46 +0200 Subject: Explain why _make_and() can return None Makes ANDs between nonexistent expressions yield a nonexistent expression. --- kconfiglib.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kconfiglib.py b/kconfiglib.py index 93b2279..19cf928 100644 --- a/kconfiglib.py +++ b/kconfiglib.py @@ -3269,7 +3269,8 @@ def _make_and(e1, e2): """Constructs an AND (&&) expression. Performs trivial simplification. Nones equate to 'y'. - Note: returns None if e1 == e2 == None.""" + Returns None if e1 == e2 == None, so that ANDing two nonexistent + expressions gives a nonexistent expression.""" if e1 is None or e1 == "y": return e2 if e2 is None or e2 == "y": -- cgit v1.2.3