From 63a44186137e2706afec0aef278cd5d123fc98dc Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Mon, 14 May 2018 14:48:22 +0200 Subject: Record which MenuNode has each property This allows accurate documentation to be generated for symbols and choices defined in multiple locations. There are now MenuNode.defaults, MenuNode.selects, etc., lists that mirror the corresponding Symbol/Choice lists. Symbol/Choice.__str__() now correctly show property locations as well, by simply concatenating the strings returned by MenuNode.__str__() for each node. _parse_properties() was modified to add all properties directly to the menu node instead of adding them to the contained symbol or choice. The properties are then copied up to symbols and choices in _finalize_tree(). Dependency propagation is handled at the same time. As a side effect, this cleans up the code a bit and de-bloats _parse_properties(). Update the menuconfig implementation to use the new functionality. It now lists the menu nodes for symbols and choices with the correct properties for each node (previously, all defaults, selects, implies, and ranges appeared on the first definition). --- tests/Kdirdep | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 tests/Kdirdep (limited to 'tests/Kdirdep') diff --git a/tests/Kdirdep b/tests/Kdirdep new file mode 100644 index 0000000..cbb88b9 --- /dev/null +++ b/tests/Kdirdep @@ -0,0 +1,30 @@ +config NO_DEP_SYM + bool + +config DEP_SYM + bool + depends on A + +config DEP_SYM + depends on B && C + +config DEP_SYM + depends on !D + + +choice NO_DEP_CHOICE + bool "no dep. choice" +endchoice + +choice DEP_CHOICE + bool "dep. choice" + depends on A +endchoice + +choice DEP_CHOICE + depends on B +endchoice + +choice DEP_CHOICE + depends on C +endchoice -- cgit v1.2.3