---
Function {
 argument: Destructured {
  identifier: None,
  arguments: [
   DestructuredArgument {
    identifier: "config",
    default: None,
   },
   DestructuredArgument {
    identifier: "lib",
    default: None,
   },
   DestructuredArgument {
    identifier: "pkgs",
    default: None,
   },
  ],
  ellipsis: true,
 },
 definition: With {
  expression: Variable {
   identifier: "lib",
   position: (3, 6),
  },
  target: LetIn {
   bindings: [
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "cfg",
        position: (6, 3),
       },
      ],
     },
     to: PropertyAccess {
      expression: Variable {
       identifier: "config",
       position: (6, 9),
      },
      attribute_path: AttributePath {
       parts: [
        Raw {
         content: "hardware",
         position: (6, 16),
        },
        Raw {
         content: "sane",
         position: (6, 25),
        },
        Raw {
         content: "brscan5",
         position: (6, 30),
        },
       ],
      },
      default: None,
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "netDeviceList",
        position: (8, 3),
       },
      ],
     },
     to: FunctionApplication {
      function: Variable {
       identifier: "attrValues",
       position: (8, 19),
      },
      arguments: [
       PropertyAccess {
        expression: Variable {
         identifier: "cfg",
         position: (8, 30),
        },
        attribute_path: AttributePath {
         parts: [
          Raw {
           content: "netDevices",
           position: (8, 34),
          },
         ],
        },
        default: None,
       },
      ],
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "etcFiles",
        position: (10, 3),
       },
      ],
     },
     to: FunctionApplication {
      function: PropertyAccess {
       expression: Variable {
        identifier: "pkgs",
        position: (10, 14),
       },
       attribute_path: AttributePath {
        parts: [
         Raw {
          content: "callPackage",
          position: (10, 19),
         },
        ],
       },
       default: None,
      },
      arguments: [
       Path {
        parts: [
         Raw {
          content: "./brscan5_etc_files.nix",
          position: (10, 31),
         },
        ],
        position: (10, 31),
       },
       Map {
        bindings: [
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "netDevices",
             position: (10, 57),
            },
           ],
          },
          to: Variable {
           identifier: "netDeviceList",
           position: (10, 70),
          },
         },
        ],
        recursive: false,
        position: (10, 55),
       },
      ],
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "netDeviceOpts",
        position: (12, 3),
       },
      ],
     },
     to: Function {
      argument: Destructured {
       identifier: None,
       arguments: [
        DestructuredArgument {
         identifier: "name",
         default: None,
        },
       ],
       ellipsis: true,
      },
      definition: Map {
       bindings: [
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "options",
            position: (14, 5),
           },
          ],
         },
         to: Map {
          bindings: [
           Binding {
            from: AttributePath {
             parts: [
              Raw {
               content: "name",
               position: (16, 7),
              },
             ],
            },
            to: FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (16, 14),
             },
             arguments: [
              Map {
               bindings: [
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "type",
                    position: (17, 9),
                   },
                  ],
                 },
                 to: PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (17, 16),
                  },
                  attribute_path: AttributePath {
                   parts: [
                    Raw {
                     content: "str",
                     position: (17, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "description",
                    position: (18, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "The friendly name you give to the network device. If undefined,\nthe name of attribute will be used.\n",
                    position: (19, 1),
                   },
                  ],
                  position: (18, 23),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "example",
                    position: (23, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "office1",
                    position: (23, 20),
                   },
                  ],
                  position: (23, 19),
                 },
                },
               ],
               recursive: false,
               position: (16, 23),
              },
             ],
            },
           },
           Binding {
            from: AttributePath {
             parts: [
              Raw {
               content: "model",
               position: (26, 7),
              },
             ],
            },
            to: FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (26, 15),
             },
             arguments: [
              Map {
               bindings: [
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "type",
                    position: (27, 9),
                   },
                  ],
                 },
                 to: PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (27, 16),
                  },
                  attribute_path: AttributePath {
                   parts: [
                    Raw {
                     content: "str",
                     position: (27, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "description",
                    position: (28, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "The model of the network device.\n",
                    position: (29, 1),
                   },
                  ],
                  position: (28, 23),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "example",
                    position: (32, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "ADS-1200",
                    position: (32, 20),
                   },
                  ],
                  position: (32, 19),
                 },
                },
               ],
               recursive: false,
               position: (26, 24),
              },
             ],
            },
           },
           Binding {
            from: AttributePath {
             parts: [
              Raw {
               content: "ip",
               position: (35, 7),
              },
             ],
            },
            to: FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (35, 12),
             },
             arguments: [
              Map {
               bindings: [
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "type",
                    position: (36, 9),
                   },
                  ],
                 },
                 to: With {
                  expression: Variable {
                   identifier: "types",
                   position: (36, 21),
                  },
                  target: FunctionApplication {
                   function: Variable {
                    identifier: "nullOr",
                    position: (36, 28),
                   },
                   arguments: [
                    Variable {
                     identifier: "str",
                     position: (36, 35),
                    },
                   ],
                  },
                  position: (36, 16),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "default",
                    position: (37, 9),
                   },
                  ],
                 },
                 to: Variable {
                  identifier: "null",
                  position: (37, 19),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "description",
                    position: (38, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "The ip address of the device. If undefined, you will have to\nprovide a nodename.\n",
                    position: (39, 1),
                   },
                  ],
                  position: (38, 23),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "example",
                    position: (43, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "192.168.1.2",
                    position: (43, 20),
                   },
                  ],
                  position: (43, 19),
                 },
                },
               ],
               recursive: false,
               position: (35, 21),
              },
             ],
            },
           },
           Binding {
            from: AttributePath {
             parts: [
              Raw {
               content: "nodename",
               position: (46, 7),
              },
             ],
            },
            to: FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (46, 18),
             },
             arguments: [
              Map {
               bindings: [
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "type",
                    position: (47, 9),
                   },
                  ],
                 },
                 to: With {
                  expression: Variable {
                   identifier: "types",
                   position: (47, 21),
                  },
                  target: FunctionApplication {
                   function: Variable {
                    identifier: "nullOr",
                    position: (47, 28),
                   },
                   arguments: [
                    Variable {
                     identifier: "str",
                     position: (47, 35),
                    },
                   ],
                  },
                  position: (47, 16),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "default",
                    position: (48, 9),
                   },
                  ],
                 },
                 to: Variable {
                  identifier: "null",
                  position: (48, 19),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "description",
                    position: (49, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "The node name of the device. If undefined, you will have to\nprovide an ip.\n",
                    position: (50, 1),
                   },
                  ],
                  position: (49, 23),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "example",
                    position: (54, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "BRW0080927AFBCE",
                    position: (54, 20),
                   },
                  ],
                  position: (54, 19),
                 },
                },
               ],
               recursive: false,
               position: (46, 27),
              },
             ],
            },
           },
          ],
          recursive: false,
          position: (14, 15),
         },
        },
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "config",
            position: (60, 5),
           },
          ],
         },
         to: Map {
          bindings: [
           Binding {
            from: AttributePath {
             parts: [
              Raw {
               content: "name",
               position: (61, 9),
              },
             ],
            },
            to: FunctionApplication {
             function: Variable {
              identifier: "mkDefault",
              position: (61, 16),
             },
             arguments: [
              Variable {
               identifier: "name",
               position: (61, 26),
              },
             ],
            },
           },
          ],
          recursive: false,
          position: (61, 7),
         },
        },
       ],
       recursive: false,
       position: (12, 34),
      },
      position: (12, 19),
     },
    },
   ],
   target: Map {
    bindings: [
     Binding {
      from: AttributePath {
       parts: [
        Raw {
         content: "options",
         position: (68, 3),
        },
       ],
      },
      to: Map {
       bindings: [
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "hardware",
            position: (70, 5),
           },
           Raw {
            content: "sane",
            position: (70, 14),
           },
           Raw {
            content: "brscan5",
            position: (70, 19),
           },
           Raw {
            content: "enable",
            position: (70, 27),
           },
          ],
         },
         to: FunctionApplication {
          function: Variable {
           identifier: "mkEnableOption",
           position: (71, 7),
          },
          arguments: [
           String {
            parts: [
             Raw {
              content: "the Brother brscan5 sane backend",
              position: (71, 23),
             },
            ],
            position: (71, 22),
           },
          ],
         },
        },
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "hardware",
            position: (73, 5),
           },
           Raw {
            content: "sane",
            position: (73, 14),
           },
           Raw {
            content: "brscan5",
            position: (73, 19),
           },
           Raw {
            content: "netDevices",
            position: (73, 27),
           },
          ],
         },
         to: FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (73, 40),
          },
          arguments: [
           Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "default",
                 position: (74, 7),
                },
               ],
              },
              to: Map {
               bindings: [],
               recursive: false,
               position: (74, 17),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "example",
                 position: (75, 7),
                },
               ],
              },
              to: Map {
               bindings: [
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "office1",
                    position: (76, 11),
                   },
                  ],
                 },
                 to: Map {
                  bindings: [
                   Binding {
                    from: AttributePath {
                     parts: [
                      Raw {
                       content: "model",
                       position: (76, 23),
                      },
                     ],
                    },
                    to: String {
                     parts: [
                      Raw {
                       content: "MFC-7860DW",
                       position: (76, 32),
                      },
                     ],
                     position: (76, 31),
                    },
                   },
                   Binding {
                    from: AttributePath {
                     parts: [
                      Raw {
                       content: "ip",
                       position: (76, 45),
                      },
                     ],
                    },
                    to: String {
                     parts: [
                      Raw {
                       content: "192.168.1.2",
                       position: (76, 51),
                      },
                     ],
                     position: (76, 50),
                    },
                   },
                  ],
                  recursive: false,
                  position: (76, 21),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "office2",
                    position: (77, 11),
                   },
                  ],
                 },
                 to: Map {
                  bindings: [
                   Binding {
                    from: AttributePath {
                     parts: [
                      Raw {
                       content: "model",
                       position: (77, 23),
                      },
                     ],
                    },
                    to: String {
                     parts: [
                      Raw {
                       content: "MFC-7860DW",
                       position: (77, 32),
                      },
                     ],
                     position: (77, 31),
                    },
                   },
                   Binding {
                    from: AttributePath {
                     parts: [
                      Raw {
                       content: "nodename",
                       position: (77, 45),
                      },
                     ],
                    },
                    to: String {
                     parts: [
                      Raw {
                       content: "BRW0080927AFBCE",
                       position: (77, 57),
                      },
                     ],
                     position: (77, 56),
                    },
                   },
                  ],
                  recursive: false,
                  position: (77, 21),
                 },
                },
               ],
               recursive: false,
               position: (76, 9),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "type",
                 position: (79, 7),
                },
               ],
              },
              to: With {
               expression: Variable {
                identifier: "types",
                position: (79, 19),
               },
               target: FunctionApplication {
                function: Variable {
                 identifier: "attrsOf",
                 position: (79, 26),
                },
                arguments: [
                 Parentheses {
                  expression: FunctionApplication {
                   function: Variable {
                    identifier: "submodule",
                    position: (79, 35),
                   },
                   arguments: [
                    Variable {
                     identifier: "netDeviceOpts",
                     position: (79, 45),
                    },
                   ],
                  },
                  position: (79, 34),
                 },
                ],
               },
               position: (79, 14),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "description",
                 position: (80, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "The list of network devices that will be registered against the brscan5\nsane backend.\n",
                 position: (81, 1),
                },
               ],
               position: (80, 21),
              },
             },
            ],
            recursive: false,
            position: (73, 49),
           },
          ],
         },
        },
       ],
       recursive: false,
       position: (68, 13),
      },
     },
     Binding {
      from: AttributePath {
       parts: [
        Raw {
         content: "config",
         position: (87, 3),
        },
       ],
      },
      to: FunctionApplication {
       function: Variable {
        identifier: "mkIf",
        position: (87, 12),
       },
       arguments: [
        Parentheses {
         expression: BinaryOperation {
          operator: LogicalAnd,
          operands: [
           PropertyAccess {
            expression: Variable {
             identifier: "config",
             position: (87, 18),
            },
            attribute_path: AttributePath {
             parts: [
              Raw {
               content: "hardware",
               position: (87, 25),
              },
              Raw {
               content: "sane",
               position: (87, 34),
              },
              Raw {
               content: "enable",
               position: (87, 39),
              },
             ],
            },
            default: None,
           },
           PropertyAccess {
            expression: Variable {
             identifier: "cfg",
             position: (87, 49),
            },
            attribute_path: AttributePath {
             parts: [
              Raw {
               content: "enable",
               position: (87, 53),
              },
             ],
            },
            default: None,
           },
          ],
          position: (87, 46),
         },
         position: (87, 17),
        },
        Map {
         bindings: [
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "hardware",
              position: (89, 5),
             },
             Raw {
              content: "sane",
              position: (89, 14),
             },
             Raw {
              content: "extraBackends",
              position: (89, 19),
             },
            ],
           },
           to: List {
            elements: [
             PropertyAccess {
              expression: Variable {
               identifier: "pkgs",
               position: (90, 7),
              },
              attribute_path: AttributePath {
               parts: [
                Raw {
                 content: "brscan5",
                 position: (90, 12),
                },
               ],
              },
              default: None,
             },
            ],
            position: (89, 35),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "environment",
              position: (93, 5),
             },
             Raw {
              content: "etc",
              position: (93, 17),
             },
             Expression {
              expression: String {
               parts: [
                Raw {
                 content: "opt/brother/scanner/brscan5",
                 position: (93, 22),
                },
               ],
               position: (93, 21),
              },
             },
            ],
           },
           to: Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "source",
                 position: (94, 9),
                },
               ],
              },
              to: String {
               parts: [
                Expression {
                 expression: Variable {
                  identifier: "etcFiles",
                  position: (94, 21),
                 },
                },
                Raw {
                 content: "/etc/opt/brother/scanner/brscan5",
                 position: (94, 30),
                },
               ],
               position: (94, 18),
              },
             },
            ],
            recursive: false,
            position: (94, 7),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "environment",
              position: (95, 5),
             },
             Raw {
              content: "etc",
              position: (95, 17),
             },
             Expression {
              expression: String {
               parts: [
                Raw {
                 content: "opt/brother/scanner/models",
                 position: (95, 22),
                },
               ],
               position: (95, 21),
              },
             },
            ],
           },
           to: Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "source",
                 position: (96, 9),
                },
               ],
              },
              to: String {
               parts: [
                Expression {
                 expression: Variable {
                  identifier: "etcFiles",
                  position: (96, 21),
                 },
                },
                Raw {
                 content: "/etc/opt/brother/scanner/brscan5/models",
                 position: (96, 30),
                },
               ],
               position: (96, 18),
              },
             },
            ],
            recursive: false,
            position: (96, 7),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "environment",
              position: (97, 5),
             },
             Raw {
              content: "etc",
              position: (97, 17),
             },
             Expression {
              expression: String {
               parts: [
                Raw {
                 content: "sane.d/dll.d/brother5.conf",
                 position: (97, 22),
                },
               ],
               position: (97, 21),
              },
             },
             Raw {
              content: "source",
              position: (97, 50),
             },
            ],
           },
           to: String {
            parts: [
             Expression {
              expression: PropertyAccess {
               expression: Variable {
                identifier: "pkgs",
                position: (97, 62),
               },
               attribute_path: AttributePath {
                parts: [
                 Raw {
                  content: "brscan5",
                  position: (97, 67),
                 },
                ],
               },
               default: None,
              },
             },
             Raw {
              content: "/etc/sane.d/dll.d/brother.conf",
              position: (97, 75),
             },
            ],
            position: (97, 59),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "assertions",
              position: (99, 5),
             },
            ],
           },
           to: List {
            elements: [
             Map {
              bindings: [
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "assertion",
                   position: (100, 9),
                  },
                 ],
                },
                to: FunctionApplication {
                 function: Variable {
                  identifier: "all",
                  position: (100, 21),
                 },
                 arguments: [
                  Parentheses {
                   expression: Function {
                    argument: Simple {
                     identifier: "x",
                    },
                    definition: UnaryOperation {
                     operator: Not,
                     operand: Parentheses {
                      expression: BinaryOperation {
                       operator: LogicalAnd,
                       operands: [
                        BinaryOperation {
                         operator: NotEqualTo,
                         operands: [
                          Variable {
                           identifier: "null",
                           position: (100, 31),
                          },
                          PropertyAccess {
                           expression: Variable {
                            identifier: "x",
                            position: (100, 39),
                           },
                           attribute_path: AttributePath {
                            parts: [
                             Raw {
                              content: "ip",
                              position: (100, 41),
                             },
                            ],
                           },
                           default: None,
                          },
                         ],
                         position: (100, 36),
                        },
                        BinaryOperation {
                         operator: NotEqualTo,
                         operands: [
                          Variable {
                           identifier: "null",
                           position: (100, 47),
                          },
                          PropertyAccess {
                           expression: Variable {
                            identifier: "x",
                            position: (100, 55),
                           },
                           attribute_path: AttributePath {
                            parts: [
                             Raw {
                              content: "nodename",
                              position: (100, 57),
                             },
                            ],
                           },
                           default: None,
                          },
                         ],
                         position: (100, 52),
                        },
                       ],
                       position: (100, 44),
                      },
                      position: (100, 30),
                     },
                     position: (100, 29),
                    },
                    position: (100, 26),
                   },
                   position: (100, 25),
                  },
                  Variable {
                   identifier: "netDeviceList",
                   position: (100, 68),
                  },
                 ],
                },
               },
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "message",
                   position: (101, 9),
                  },
                 ],
                },
                to: String {
                 parts: [
                  Raw {
                   content: "When describing a network device as part of the attribute list\n`hardware.sane.brscan5.netDevices`, only one of its `ip` or `nodename`\nattribute should be specified, not both!\n",
                   position: (102, 1),
                  },
                 ],
                 position: (101, 19),
                },
               },
              ],
              recursive: false,
              position: (100, 7),
             },
            ],
            position: (99, 18),
           },
          },
         ],
         recursive: false,
         position: (87, 61),
        },
       ],
      },
     },
    ],
    recursive: false,
    position: (67, 1),
   },
   position: (5, 1),
  },
  position: (3, 1),
 },
 position: (1, 1),
}