summaryrefslogtreecommitdiff
path: root/kconfiglib.py
diff options
context:
space:
mode:
authorUlf Magnusson <ulfalizer@gmail.com>2018-01-29 13:34:49 +0100
committerUlf Magnusson <ulfalizer@gmail.com>2018-01-29 13:36:41 +0100
commit60d129111d8195eb61a010994e9fc974365a4d63 (patch)
treedce76fc84b0a510defe91298ba8f05e83bb3bff0 /kconfiglib.py
parent797221c4e39fbc584ba67c1bbecff383441923ff (diff)
Warn if help text is empty
Personal pet peeve. Should add a warning to the C implementation too.
Diffstat (limited to 'kconfiglib.py')
-rw-r--r--kconfiglib.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/kconfiglib.py b/kconfiglib.py
index 94b5cd4..7b91b6e 100644
--- a/kconfiglib.py
+++ b/kconfiglib.py
@@ -1771,6 +1771,9 @@ class Kconfig(object):
break
if not line:
+ self._warn("{} has 'help' but empty help text"
+ .format(_name_and_loc_str(node.item)))
+
node.help = ""
break
@@ -1778,6 +1781,9 @@ class Kconfig(object):
if indent == 0:
# If the first non-empty lines has zero indent, there is no
# help text
+ self._warn("{} has 'help' but empty help text"
+ .format(_name_and_loc_str(node.item)))
+
node.help = ""
self._saved_line = line # "Unget" the line
break