2023-05-03 10:16:29 +03:00
|
|
|
let
|
|
|
|
inherit (builtins) concatStringsSep attrNames;
|
|
|
|
in
|
|
|
|
|
|
|
|
builtinsInfo:
|
2022-11-24 14:47:08 +02:00
|
|
|
let
|
|
|
|
showBuiltin = name:
|
|
|
|
let
|
2023-05-03 10:16:29 +03:00
|
|
|
inherit (builtinsInfo.${name}) doc args;
|
2022-11-24 14:47:08 +02:00
|
|
|
in
|
|
|
|
''
|
|
|
|
<dt id="builtins-${name}">
|
|
|
|
<a href="#builtins-${name}"><code>${name} ${listArgs args}</code></a>
|
|
|
|
</dt>
|
|
|
|
<dd>
|
2020-09-16 15:55:24 +03:00
|
|
|
|
2022-11-24 14:47:08 +02:00
|
|
|
${doc}
|
|
|
|
|
|
|
|
</dd>
|
|
|
|
'';
|
2023-05-03 10:16:29 +03:00
|
|
|
listArgs = args: concatStringsSep " " (map (s: "<var>${s}</var>") args);
|
2022-11-24 14:47:08 +02:00
|
|
|
in
|
2023-05-03 10:16:29 +03:00
|
|
|
concatStringsSep "\n" (map showBuiltin (attrNames builtinsInfo))
|
2020-09-16 15:55:24 +03:00
|
|
|
|