From ed39532ddaa561acfb89bd8e29899cdb835b2ea2 Mon Sep 17 00:00:00 2001 From: Domen Kožar Date: Thu, 11 Aug 2016 12:32:24 +0200 Subject: doc: add an example for builtins.substring --- doc/manual/expressions/builtins.xml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/manual/expressions/builtins.xml b/doc/manual/expressions/builtins.xml index 5fd93c831ed6..6ac802343236 100644 --- a/doc/manual/expressions/builtins.xml +++ b/doc/manual/expressions/builtins.xml @@ -853,7 +853,14 @@ builtins.sort builtins.lessThan [ 483 249 526 147 42 77 ] len lies beyond the end of the string, only the substring up to the end of the string is returned. start must be - non-negative. + non-negative. For example, + + +builtins.substring 0 3 "nixos" + + + evaluates to "nix". + -- cgit 1.4.1