Skip to content

Commit

Permalink
lib/options: Add hint for debugging infinite recursion in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
roberth committed Jun 27, 2022
1 parent 4923701 commit 4a8bc4f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/options.nix
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,8 @@ rec {
in if ss != {} then optionAttrSetToDocList' opt.loc ss else [];
subOptionsVisible = docOption.visible && opt.visible or null != "shallow";
in
# To find infinite recursion in NixOS option docs:
# builtins.trace opt.loc
[ docOption ] ++ optionals subOptionsVisible subOptions) (collect isOption options);


Expand Down

0 comments on commit 4a8bc4f

Please sign in to comment.