fake.modules transposition for aspect-oriented Dendritic Nix. with cross-aspect dependencies. Discussions: https://oeiuwq.zulipchat.com/join/nqp26cd4kngon6mo3ncgnuap/ dendrix.oeiuwq.com/Dendritic.html
dendritic nix aspect oriented

map items

+3 -10
+3 -10
default.nix
··· 1 1 lib: 2 2 let 3 3 transposeChild = child: parent: value: { inherit child parent value; }; 4 - 5 4 accTransposed = 6 - acc: 7 - { 8 - parent, 9 - child, 10 - value, 11 - }: 5 + acc: item: 12 6 acc 13 7 // { 14 - ${parent} = (acc.${parent} or { }) // { 15 - ${child} = value; 8 + ${item.parent} = (acc.${item.parent} or { }) // { 9 + ${item.child} = item.value; 16 10 }; 17 11 }; 18 - 19 12 eachChildAttrs = parent: lib.mapAttrsToList (transposeChild parent); 20 13 deconstruct = lib.mapAttrsToList eachChildAttrs; 21 14 reconstruct = lib.foldl accTransposed { };