---
Function {
 argument: Destructured {
  identifier: None,
  arguments: [
   DestructuredArgument {
    identifier: "config",
    default: None,
   },
   DestructuredArgument {
    identifier: "pkgs",
    default: None,
   },
   DestructuredArgument {
    identifier: "lib",
    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: "i18n",
         position: (6, 16),
        },
        Raw {
         content: "inputMethod",
         position: (6, 21),
        },
        Raw {
         content: "ibus",
         position: (6, 33),
        },
       ],
      },
      default: None,
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "ibusPackage",
        position: (7, 3),
       },
      ],
     },
     to: FunctionApplication {
      function: PropertyAccess {
       expression: Variable {
        identifier: "pkgs",
        position: (7, 17),
       },
       attribute_path: AttributePath {
        parts: [
         Raw {
          content: "ibus-with-plugins",
          position: (7, 22),
         },
         Raw {
          content: "override",
          position: (7, 40),
         },
        ],
       },
       default: None,
      },
      arguments: [
       Map {
        bindings: [
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "plugins",
             position: (7, 51),
            },
           ],
          },
          to: PropertyAccess {
           expression: Variable {
            identifier: "cfg",
            position: (7, 61),
           },
           attribute_path: AttributePath {
            parts: [
             Raw {
              content: "engines",
              position: (7, 65),
             },
            ],
           },
           default: None,
          },
         },
        ],
        recursive: false,
        position: (7, 49),
       },
      ],
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "ibusEngine",
        position: (8, 3),
       },
      ],
     },
     to: BinaryOperation {
      operator: Update,
      operands: [
       PropertyAccess {
        expression: Variable {
         identifier: "types",
         position: (8, 16),
        },
        attribute_path: AttributePath {
         parts: [
          Raw {
           content: "package",
           position: (8, 22),
          },
         ],
        },
        default: None,
       },
       Map {
        bindings: [
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "name",
             position: (9, 5),
            },
           ],
          },
          to: String {
           parts: [
            Raw {
             content: "ibus-engine",
             position: (9, 14),
            },
           ],
           position: (9, 13),
          },
         },
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "check",
             position: (10, 5),
            },
           ],
          },
          to: Function {
           argument: Simple {
            identifier: "x",
           },
           definition: BinaryOperation {
            operator: LogicalAnd,
            operands: [
             Parentheses {
              expression: FunctionApplication {
               function: PropertyAccess {
                expression: Variable {
                 identifier: "lib",
                 position: (10, 17),
                },
                attribute_path: AttributePath {
                 parts: [
                  Raw {
                   content: "types",
                   position: (10, 21),
                  },
                  Raw {
                   content: "package",
                   position: (10, 27),
                  },
                  Raw {
                   content: "check",
                   position: (10, 35),
                  },
                 ],
                },
                default: None,
               },
               arguments: [
                Variable {
                 identifier: "x",
                 position: (10, 41),
                },
               ],
              },
              position: (10, 16),
             },
             Parentheses {
              expression: FunctionApplication {
               function: Variable {
                identifier: "attrByPath",
                position: (10, 48),
               },
               arguments: [
                List {
                 elements: [
                  String {
                   parts: [
                    Raw {
                     content: "meta",
                     position: (10, 61),
                    },
                   ],
                   position: (10, 60),
                  },
                  String {
                   parts: [
                    Raw {
                     content: "isIbusEngine",
                     position: (10, 68),
                    },
                   ],
                   position: (10, 67),
                  },
                 ],
                 position: (10, 59),
                },
                Variable {
                 identifier: "false",
                 position: (10, 83),
                },
                Variable {
                 identifier: "x",
                 position: (10, 89),
                },
               ],
              },
              position: (10, 47),
             },
            ],
            position: (10, 44),
           },
           position: (10, 13),
          },
         },
        ],
        recursive: false,
        position: (8, 33),
       },
      ],
      position: (8, 30),
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "impanel",
        position: (13, 3),
       },
      ],
     },
     to: IfThenElse {
      predicate: BinaryOperation {
       operator: NotEqualTo,
       operands: [
        PropertyAccess {
         expression: Variable {
          identifier: "cfg",
          position: (14, 8),
         },
         attribute_path: AttributePath {
          parts: [
           Raw {
            content: "panel",
            position: (14, 12),
           },
          ],
         },
         default: None,
        },
        Variable {
         identifier: "null",
         position: (14, 21),
        },
       ],
       position: (14, 18),
      },
      then: String {
       parts: [
        Raw {
         content: "--panel=",
         position: (15, 11),
        },
        Interpolation {
         expression: PropertyAccess {
          expression: Variable {
           identifier: "cfg",
           position: (15, 21),
          },
          attribute_path: AttributePath {
           parts: [
            Raw {
             content: "panel",
             position: (15, 25),
            },
           ],
          },
          default: None,
         },
        },
       ],
       position: (15, 10),
      },
      else_: String {
       parts: [],
       position: (16, 10),
      },
      position: (14, 5),
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "ibusAutostart",
        position: (18, 3),
       },
      ],
     },
     to: FunctionApplication {
      function: PropertyAccess {
       expression: Variable {
        identifier: "pkgs",
        position: (18, 19),
       },
       attribute_path: AttributePath {
        parts: [
         Raw {
          content: "writeTextFile",
          position: (18, 24),
         },
        ],
       },
       default: None,
      },
      arguments: [
       Map {
        bindings: [
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "name",
             position: (19, 5),
            },
           ],
          },
          to: String {
           parts: [
            Raw {
             content: "autostart-ibus-daemon",
             position: (19, 13),
            },
           ],
           position: (19, 12),
          },
         },
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "destination",
             position: (20, 5),
            },
           ],
          },
          to: String {
           parts: [
            Raw {
             content: "/etc/xdg/autostart/ibus-daemon.desktop",
             position: (20, 20),
            },
           ],
           position: (20, 19),
          },
         },
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "text",
             position: (21, 5),
            },
           ],
          },
          to: String {
           parts: [
            Raw {
             content: "[Desktop Entry]\nName=IBus\nType=Application\nExec=",
             position: (22, 1),
            },
            Interpolation {
             expression: Variable {
              identifier: "ibusPackage",
              position: (25, 14),
             },
            },
            Raw {
             content: "/bin/ibus-daemon --daemonize --xim ",
             position: (25, 26),
            },
            Interpolation {
             expression: Variable {
              identifier: "impanel",
              position: (25, 63),
             },
            },
            Raw {
             content: "\n",
             position: (25, 71),
            },
           ],
           position: (21, 12),
          },
         },
        ],
        recursive: false,
        position: (18, 38),
       },
      ],
     },
    },
   ],
   target: Map {
    bindings: [
     Binding {
      from: AttributePath {
       parts: [
        Raw {
         content: "imports",
         position: (30, 3),
        },
       ],
      },
      to: List {
       elements: [
        Parentheses {
         expression: FunctionApplication {
          function: Variable {
           identifier: "mkRenamedOptionModule",
           position: (31, 6),
          },
          arguments: [
           List {
            elements: [
             String {
              parts: [
               Raw {
                content: "programs",
                position: (31, 31),
               },
              ],
              position: (31, 30),
             },
             String {
              parts: [
               Raw {
                content: "ibus",
                position: (31, 42),
               },
              ],
              position: (31, 41),
             },
             String {
              parts: [
               Raw {
                content: "plugins",
                position: (31, 49),
               },
              ],
              position: (31, 48),
             },
            ],
            position: (31, 28),
           },
           List {
            elements: [
             String {
              parts: [
               Raw {
                content: "i18n",
                position: (31, 63),
               },
              ],
              position: (31, 62),
             },
             String {
              parts: [
               Raw {
                content: "inputMethod",
                position: (31, 70),
               },
              ],
              position: (31, 69),
             },
             String {
              parts: [
               Raw {
                content: "ibus",
                position: (31, 84),
               },
              ],
              position: (31, 83),
             },
             String {
              parts: [
               Raw {
                content: "engines",
                position: (31, 91),
               },
              ],
              position: (31, 90),
             },
            ],
            position: (31, 60),
           },
          ],
         },
         position: (31, 5),
        },
       ],
       position: (30, 13),
      },
     },
     Binding {
      from: AttributePath {
       parts: [
        Raw {
         content: "options",
         position: (34, 3),
        },
       ],
      },
      to: Map {
       bindings: [
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "i18n",
            position: (35, 5),
           },
           Raw {
            content: "inputMethod",
            position: (35, 10),
           },
           Raw {
            content: "ibus",
            position: (35, 22),
           },
          ],
         },
         to: Map {
          bindings: [
           Binding {
            from: AttributePath {
             parts: [
              Raw {
               content: "engines",
               position: (36, 7),
              },
             ],
            },
            to: FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (36, 17),
             },
             arguments: [
              Map {
               bindings: [
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "type",
                    position: (37, 9),
                   },
                  ],
                 },
                 to: With {
                  expression: Variable {
                   identifier: "types",
                   position: (37, 24),
                  },
                  target: FunctionApplication {
                   function: Variable {
                    identifier: "listOf",
                    position: (37, 31),
                   },
                   arguments: [
                    Variable {
                     identifier: "ibusEngine",
                     position: (37, 38),
                    },
                   ],
                  },
                  position: (37, 19),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "default",
                    position: (38, 9),
                   },
                  ],
                 },
                 to: List {
                  elements: [],
                  position: (38, 19),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "example",
                    position: (39, 9),
                   },
                  ],
                 },
                 to: FunctionApplication {
                  function: Variable {
                   identifier: "literalExpression",
                   position: (39, 19),
                  },
                  arguments: [
                   String {
                    parts: [
                     Raw {
                      content: "with pkgs.ibus-engines; [ mozc hangul ]",
                      position: (39, 38),
                     },
                    ],
                    position: (39, 37),
                   },
                  ],
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "description",
                    position: (40, 9),
                   },
                  ],
                 },
                 to: LetIn {
                  bindings: [
                   Binding {
                    from: AttributePath {
                     parts: [
                      Raw {
                       content: "enginesDrv",
                       position: (42, 13),
                      },
                     ],
                    },
                    to: FunctionApplication {
                     function: Variable {
                      identifier: "filterAttrs",
                      position: (42, 26),
                     },
                     arguments: [
                      Parentheses {
                       expression: FunctionApplication {
                        function: Variable {
                         identifier: "const",
                         position: (42, 39),
                        },
                        arguments: [
                         Variable {
                          identifier: "isDerivation",
                          position: (42, 45),
                         },
                        ],
                       },
                       position: (42, 38),
                      },
                      PropertyAccess {
                       expression: Variable {
                        identifier: "pkgs",
                        position: (42, 59),
                       },
                       attribute_path: AttributePath {
                        parts: [
                         Raw {
                          content: "ibus-engines",
                          position: (42, 64),
                         },
                        ],
                       },
                       default: None,
                      },
                     ],
                    },
                   },
                   Binding {
                    from: AttributePath {
                     parts: [
                      Raw {
                       content: "engines",
                       position: (43, 13),
                      },
                     ],
                    },
                    to: FunctionApplication {
                     function: Variable {
                      identifier: "concatStringsSep",
                      position: (43, 23),
                     },
                     arguments: [
                      String {
                       parts: [
                        Raw {
                         content: ", ",
                         position: (43, 41),
                        },
                       ],
                       position: (43, 40),
                      },
                      Parentheses {
                       expression: FunctionApplication {
                        function: Variable {
                         identifier: "map",
                         position: (44, 16),
                        },
                        arguments: [
                         Parentheses {
                          expression: Function {
                           argument: Simple {
                            identifier: "name",
                           },
                           definition: String {
                            parts: [
                             Raw {
                              content: "<literal>",
                              position: (44, 28),
                             },
                             Interpolation {
                              expression: Variable {
                               identifier: "name",
                               position: (44, 39),
                              },
                             },
                             Raw {
                              content: "</literal>",
                              position: (44, 44),
                             },
                            ],
                            position: (44, 27),
                           },
                           position: (44, 21),
                          },
                          position: (44, 20),
                         },
                         Parentheses {
                          expression: FunctionApplication {
                           function: Variable {
                            identifier: "attrNames",
                            position: (44, 58),
                           },
                           arguments: [
                            Variable {
                             identifier: "enginesDrv",
                             position: (44, 68),
                            },
                           ],
                          },
                          position: (44, 57),
                         },
                        ],
                       },
                       position: (44, 15),
                      },
                     ],
                    },
                   },
                  ],
                  target: String {
                   parts: [
                    Raw {
                     content: "Enabled IBus engines. Available engines are: ",
                     position: (46, 14),
                    },
                    Interpolation {
                     expression: Variable {
                      identifier: "engines",
                      position: (46, 61),
                     },
                    },
                    Raw {
                     content: ".",
                     position: (46, 69),
                    },
                   ],
                   position: (46, 13),
                  },
                  position: (41, 11),
                 },
                },
               ],
               recursive: false,
               position: (36, 26),
              },
             ],
            },
           },
           Binding {
            from: AttributePath {
             parts: [
              Raw {
               content: "panel",
               position: (48, 7),
              },
             ],
            },
            to: FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (48, 15),
             },
             arguments: [
              Map {
               bindings: [
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "type",
                    position: (49, 9),
                   },
                  ],
                 },
                 to: With {
                  expression: Variable {
                   identifier: "types",
                   position: (49, 21),
                  },
                  target: FunctionApplication {
                   function: Variable {
                    identifier: "nullOr",
                    position: (49, 28),
                   },
                   arguments: [
                    Variable {
                     identifier: "path",
                     position: (49, 35),
                    },
                   ],
                  },
                  position: (49, 16),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "default",
                    position: (50, 9),
                   },
                  ],
                 },
                 to: Variable {
                  identifier: "null",
                  position: (50, 19),
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "example",
                    position: (51, 9),
                   },
                  ],
                 },
                 to: FunctionApplication {
                  function: Variable {
                   identifier: "literalExpression",
                   position: (51, 19),
                  },
                  arguments: [
                   String {
                    parts: [
                     Raw {
                      content: "\"",
                      position: (51, 39),
                     },
                     Raw {
                      content: "$",
                      position: (51, 40),
                     },
                     Raw {
                      content: "{pkgs.plasma5Packages.plasma-desktop}/lib/libexec/kimpanel-ibus-panel\"",
                      position: (51, 43),
                     },
                    ],
                    position: (51, 37),
                   },
                  ],
                 },
                },
                Binding {
                 from: AttributePath {
                  parts: [
                   Raw {
                    content: "description",
                    position: (52, 9),
                   },
                  ],
                 },
                 to: String {
                  parts: [
                   Raw {
                    content: "Replace the IBus panel with another panel.",
                    position: (52, 24),
                   },
                  ],
                  position: (52, 23),
                 },
                },
               ],
               recursive: false,
               position: (48, 24),
              },
             ],
            },
           },
          ],
          recursive: false,
          position: (35, 29),
         },
        },
       ],
       recursive: false,
       position: (34, 13),
      },
     },
     Binding {
      from: AttributePath {
       parts: [
        Raw {
         content: "config",
         position: (57, 3),
        },
       ],
      },
      to: FunctionApplication {
       function: Variable {
        identifier: "mkIf",
        position: (57, 12),
       },
       arguments: [
        Parentheses {
         expression: BinaryOperation {
          operator: EqualTo,
          operands: [
           PropertyAccess {
            expression: Variable {
             identifier: "config",
             position: (57, 18),
            },
            attribute_path: AttributePath {
             parts: [
              Raw {
               content: "i18n",
               position: (57, 25),
              },
              Raw {
               content: "inputMethod",
               position: (57, 30),
              },
              Raw {
               content: "enabled",
               position: (57, 42),
              },
             ],
            },
            default: None,
           },
           String {
            parts: [
             Raw {
              content: "ibus",
              position: (57, 54),
             },
            ],
            position: (57, 53),
           },
          ],
          position: (57, 50),
         },
         position: (57, 17),
        },
        Map {
         bindings: [
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "i18n",
              position: (58, 5),
             },
             Raw {
              content: "inputMethod",
              position: (58, 10),
             },
             Raw {
              content: "package",
              position: (58, 22),
             },
            ],
           },
           to: Variable {
            identifier: "ibusPackage",
            position: (58, 32),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "environment",
              position: (60, 5),
             },
             Raw {
              content: "systemPackages",
              position: (60, 17),
             },
            ],
           },
           to: List {
            elements: [
             Variable {
              identifier: "ibusAutostart",
              position: (61, 7),
             },
            ],
            position: (60, 34),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "programs",
              position: (65, 5),
             },
             Raw {
              content: "dconf",
              position: (65, 14),
             },
             Raw {
              content: "enable",
              position: (65, 20),
             },
            ],
           },
           to: Variable {
            identifier: "true",
            position: (65, 29),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "programs",
              position: (67, 5),
             },
             Raw {
              content: "dconf",
              position: (67, 14),
             },
             Raw {
              content: "packages",
              position: (67, 20),
             },
            ],
           },
           to: List {
            elements: [
             Variable {
              identifier: "ibusPackage",
              position: (67, 33),
             },
            ],
            position: (67, 31),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "services",
              position: (69, 5),
             },
             Raw {
              content: "dbus",
              position: (69, 14),
             },
             Raw {
              content: "packages",
              position: (69, 19),
             },
            ],
           },
           to: List {
            elements: [
             Variable {
              identifier: "ibusAutostart",
              position: (70, 7),
             },
            ],
            position: (69, 30),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "environment",
              position: (73, 5),
             },
             Raw {
              content: "variables",
              position: (73, 17),
             },
            ],
           },
           to: Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "GTK_IM_MODULE",
                 position: (74, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "ibus",
                 position: (74, 24),
                },
               ],
               position: (74, 23),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "QT_IM_MODULE",
                 position: (75, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "ibus",
                 position: (75, 23),
                },
               ],
               position: (75, 22),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "XMODIFIERS",
                 position: (76, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "@im=ibus",
                 position: (76, 21),
                },
               ],
               position: (76, 20),
              },
             },
            ],
            recursive: false,
            position: (73, 29),
           },
          },
          Binding {
           from: AttributePath {
            parts: [
             Raw {
              content: "xdg",
              position: (79, 5),
             },
             Raw {
              content: "portal",
              position: (79, 9),
             },
             Raw {
              content: "extraPortals",
              position: (79, 16),
             },
            ],
           },
           to: FunctionApplication {
            function: Variable {
             identifier: "mkIf",
             position: (79, 31),
            },
            arguments: [
             PropertyAccess {
              expression: Variable {
               identifier: "config",
               position: (79, 36),
              },
              attribute_path: AttributePath {
               parts: [
                Raw {
                 content: "xdg",
                 position: (79, 43),
                },
                Raw {
                 content: "portal",
                 position: (79, 47),
                },
                Raw {
                 content: "enable",
                 position: (79, 54),
                },
               ],
              },
              default: None,
             },
             List {
              elements: [
               Variable {
                identifier: "ibusPackage",
                position: (80, 7),
               },
              ],
              position: (79, 61),
             },
            ],
           },
          },
         ],
         recursive: false,
         position: (57, 61),
        },
       ],
      },
     },
     Binding {
      from: AttributePath {
       parts: [
        Raw {
         content: "meta",
         position: (85, 3),
        },
        Raw {
         content: "buildDocsInSandbox",
         position: (85, 8),
        },
       ],
      },
      to: Variable {
       identifier: "false",
       position: (85, 29),
      },
     },
    ],
    recursive: false,
    position: (29, 1),
   },
   position: (5, 1),
  },
  position: (3, 1),
 },
 position: (1, 1),
}