From c406fcf1947f30b824449f30e7658bb2f7924419 Mon Sep 17 00:00:00 2001 From: Michael Raskin <7c6f434c@mail.ru> Date: Wed, 27 Aug 2008 21:19:03 +0000 Subject: [PATCH] Some diagnostics for NixOS manual helper svn path=/nixpkgs/trunk/; revision=12756 --- pkgs/lib/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/lib/default.nix b/pkgs/lib/default.nix index cf0732ef8681..2f87de0cd0c6 100644 --- a/pkgs/lib/default.nix +++ b/pkgs/lib/default.nix @@ -454,7 +454,9 @@ rec { optionAttrSetToDocList = (l: attrs: (if (getAttr ["_type"] "" attrs) == "option" then [({ - inherit (attrs) description; + #inherit (attrs) description; + description = if attrs ? description then attrs.description else + throw ("No description ${toString l}"); } //(if attrs ? example then {inherit(attrs) example;} else {} ) //(if attrs ? default then {inherit(attrs) default;} else {} )