anchor.diff:      let
         # remove possible mkIf to access the require attribute.
         noImportConditions = cfgSet0:
  -        let cfgSet1 = delayIf cfgSet0; in
  +        let cfgSet1 = delayProperties cfgSet0; in
           if cfgSet1 ? require then
  -          cfgSet1 // { require = rmIf cfgSet1.require; }
  +          cfgSet1 // { require = rmProperties cfgSet1.require; }
           else
             cfgSet1;
   
  
positive.code:         (l + (if l=="" then "" else ".") + s) (builtins.getAttr s attrs)))
          (builtins.attrNames attrs)));
  
          
    /* If. ThenElse. Always. */
    # !!! cleanup needed
  
    # create "if" statement that can be dealyed on sets until a "then-else" or
    # "always" set is reached.  When an always set is reached the condition
    # is ignore.
  
    isIf = attrs: (typeOf attrs) == "if";
    mkIf = condition: thenelse:
      if isIf thenelse then
        mkIf (condition && thenelse.condition) thenelse.thenelse
      else {
        _type = "if";
        inherit condition thenelse;
      };
  
  
    isNotdef = attrs: (typeOf attrs) == "notdef";
    mkNotdef = {_type = "notdef";};
  
  
    isThenElse = attrs: (typeOf attrs) == "then-else";
    mkThenElse = attrs:
      assert attrs ? thenPart && attrs ? elsePart;
      attrs // { _type = "then-else"; };
  
  
    isAlways = attrs: (typeOf attrs) == "always";
    mkAlways = value: { inherit value; _type = "always"; };
  
    pushIf = f: attrs:
      if isIf attrs then pushIf f (
        let val = attrs.thenelse; in
        # evaluate the condition.
        if isThenElse val then
          if attrs.condition then
            val.thenPart
          else
            val.elsePart
        # ignore the condition.
        else if isAlways val then
          val.value
        # otherwise
        else
          f attrs.condition val)
      else
        attrs;
  
    # take care otherwise you will have to handle this by hand.
    rmIf = pushIf (condition: val: val);
  
    evalIf = pushIf (condition: val:
      if condition then val else mkNotdef
    );
  
    delayIf = pushIf (condition: val:
      # rewrite the condition on sub-attributes.
      lib.mapAttrs (name: mkIf condition) val
    );
  
  }
negative.code:             cfg2 = noImportConditions cfg1;
          in cfg2;
  
        getRequire = x:
          toList (getAttr ["require"] [] (preprocess x));
        getCleanRequire = x: map rmProperties (getRequire x);
        rmRequire = x: removeAttrs (preprocess x) ["require"];
  
        duplicateIncludeProperties = list:
          # iterate on all configurations
          fold (cfg: l:
            # iterate on all imported configuration from cfg
            fold (include: l:
              # clean up the included cfg to get the same result
              let includedCfg = rmProperties include; in
              # if the include has properties
              if include != includedCfg then
                # iterate on all configurations
                map (cfg:
                  # if the imported configuration is seen
                  if (rmProperties cfg) == includedCfg then
                    # copy the properties from the import to the configuration.
                    delayProperties (copyProperties include cfg)
                  else
                    cfg
                ) l
              else
                l
            ) l (getRequire cfg)
          ) list list;
      in
        merge "" (
          map rmRequire (
            duplicateIncludeProperties (
              lib.uniqFlatten getCleanRequire [] [] (toList opts)
            )
          )
        );
  
  