toonn
2698fe8611
manual: Update Attribute Set section to exclude indented strings and URIs
Indented strings and URIs are string literals but they are not allowed
as names for attrsets, `let` or `inherit`. The following snippets
illustrate that they lead to syntax errors.
==> examples/ind_str-attr.nix <==
{
''indented string'' = "error: syntax error, expecting '}'";
}
==> examples/ind_str-inherit.nix <==
{ inherit ({ "non-indented string" = "error: syntax error, expecting ';'"; })
''non-indented string'';
}
==> examples/ind_str-let.nix <==
let
''indented string'' = "error: syntax error, expecting 'in'";
in
true
==> examples/uri-attr.nix <==
{
http://example.org/foo.tar.bz2 = "error: syntax error, expecting '}'";
}
==> examples/uri-inherit.nix <==
{ inherit ({ "http://example.org/foo.tar.bz2" = "error: syntax error, expecting ';'"; })
http://example.org/foo.tar.bz2;
}
==> examples/uri-let.nix <==
let
http://example.org/foo.tar.bz2 = "error: syntax error, expecting 'in'";
in
true
Change-Id: I6774af93baf9f533877642a563775667c518ea88
2026-06-06 14:52:54 +00:00
..
2026-03-13 16:24:51 +01:00
2025-03-18 04:20:00 +00:00
2026-03-21 23:16:30 +01:00
2026-05-18 18:13:47 +02:00
2020-07-24 12:58:31 +02:00
2025-10-30 00:04:21 +01:00
2025-11-14 21:36:48 +01:00
2026-06-06 14:52:54 +00:00
2025-11-20 14:47:51 +00:00
2025-05-12 13:37:54 +02:00
2026-03-13 09:06:04 -07:00
2024-03-29 22:57:40 -07:00
2025-12-11 07:46:10 +00:00
2025-03-18 04:20:00 +00:00
2026-04-13 14:18:09 -04:00
2026-03-13 09:06:04 -07:00