anchor.diff:  let
   
     # Remove invisible and internal options.
  -  options' = filter (opt: opt.visible && !opt.internal) (optionAttrSetToDocList options);
  +  optionsList = filter (opt: opt.visible && !opt.internal) (optionAttrSetToDocList options);
  +
  +  # Replace functions by the string <function>
  +  substFunction = x:
  +    if builtins.isAttrs x then mapAttrs (name: substFunction) x
  +    else if builtins.isList x then map substFunction x
  +    else if builtins.isFunction x then "<function>"
  +    else x;
   
     # Clean up declaration sites to not refer to the NixOS source tree.
  -  options'' = flip map options' (opt: opt // {
  +  optionsList' = flip map optionsList (opt: opt // {
       declarations = map (fn: stripPrefix fn) opt.declarations;
  -  });
  +  }
  +  // optionalAttrs (opt ? example) { example = substFunction opt.example; }
  +  // optionalAttrs (opt ? default) { default = substFunction opt.default; });
   
     prefix = toString ../../..;
   
  
positive.code:     else
        fn;
  
    optionsXML = builtins.toFile "options.xml" (builtins.unsafeDiscardStringContext (builtins.toXML options''));
  
    optionsDocBook = runCommand "options-db.xml" {} ''
      if grep /nixpkgs/nixos/modules ${optionsXML}; then
        echo "The manual appears to depend on the location of Nixpkgs, which is bad"
        echo "since this prevents sharing via the NixOS channel.  This is typically"
        echo "caused by an option default that refers to a relative path (see above"
  
negative.code:     fi
      ${libxslt}/bin/xsltproc \
        --stringparam revision '${revision}' \
        -o $out ${./options-to-docbook.xsl} $optionsXML
    '';
  
    sources = sourceFilesBySuffices ./. [".xml"];
  