anchor.diff:        name = builtins.head (splitString sep filename);
       in assert name !=  filename; name;
   
  -
  -  # Create an --{enable,disable}-<feat> string that can be passed to
  -  # standard GNU Autoconf scripts.
  +  /* Create an --{enable,disable}-<feat> string that can be passed to
  +     standard GNU Autoconf scripts.
  +
  +     Example:
  +       enableFeature true "shared"
  +       => "--enable-shared"
  +       enableFeature false "shared"
  +       => "--disable-shared"
  +  */
     enableFeature = enable: feat: "--${if enable then "enable" else "disable"}-${feat}";
   
  -
  -  # Create a fixed width string with additional prefix to match
  -  # required width.
  +  /* Create a fixed width string with additional prefix to match
  +     required width.
  +
  +     Example:
  +       fixedWidthString 5 "0" (toString 15)
  +       => "00015"
  +  */
     fixedWidthString = width: filler: str:
       let
         strw = lib.stringLength str;
  
positive.code:     in
        recurse 0 0;
  
  
    # return the suffix of the second argument if the first argument match its
    # prefix. e.g.,
    # `removePrefix "foo." "foo.bar.baz"' returns "bar.baz".
    removePrefix = pre: s:
      let
        preLen = stringLength pre;
  
negative.code:     in lenStr >= lenSuff &&
         substring (lenStr - lenSuff) lenStr str == suff;
  
    /* Convert a string to a list of characters (i.e. singleton strings).
       This allows you to, e.g., map a function over each character.  However,
       note that this will likely be horribly inefficient; Nix is not a
       general purpose programming language. Complex string manipulations
       should, if appropriate, be done in a derivation.
       Also note that Nix treats strings as a list of bytes and thus doesn't
       handle unicode.
  
       Example:
         stringToCharacters ""
         => [ ]
         stringToCharacters "abc"
         => [ "a" "b" "c" ]
         stringToCharacters "💩"
         => [ "�" "�" "�" "�" ]
    */
    stringToCharacters = s:
      map (p: substring p 1 s) (lib.range 0 (stringLength s - 1));
  
    /* Manipulate a string character by character and replace them by
       strings before concatenating the results.
  
       Example:
         stringAsChars (x: if x == "a" then "i" else x) "nax"
         => "nix"
    */
    stringAsChars = f: s:
      concatStrings (
        map f (stringToCharacters s)
      );
  
    /* Escape occurrence of the elements of ‘list’ in ‘string’ by
       prefixing it with a backslash.
  
       Example:
         escape ["(" ")"] "(foo)"
         => "\\(foo\\)"
    */
    escape = list: replaceChars list (map (c: "\\${c}") list);
  
    /* Escape all characters that have special meaning in the Bourne shell.
  
       Example:
         escapeShellArg "so([<>])me"
         => "so\\(\\[\\<\\>\\]\\)me"
    */
    escapeShellArg = lib.escape (stringToCharacters "\\ ';$`()|<>\t*[]");
  
    /* Obsolete - use replaceStrings instead. */
    replaceChars = builtins.replaceStrings or (
      del: new: s:
      let
  