Function( Function { head: Destructured( FunctionHeadDestructured { ellipsis: false, identifier: None, arguments: [ FunctionHeadDestructuredArgument { identifier: "lib", default: None, }, ], }, ), body: LetIn( LetIn { bindings: [ Inherit( BindingInherit { from: Some( PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "lib", span: Span { start: Position { line: 5, column: 12, }, end: Position { line: 5, column: 15, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "strings", span: Span { start: Position { line: 5, column: 16, }, end: Position { line: 5, column: 23, }, }, }, ), ], default: None, }, ), ), attributes: [ Raw( PartRaw { content: "toInt", span: Span { start: Position { line: 5, column: 25, }, end: Position { line: 5, column: 30, }, }, }, ), ], span: Span { start: Position { line: 4, column: 4, }, end: Position { line: 5, column: 31, }, }, }, ), Inherit( BindingInherit { from: Some( PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "lib", span: Span { start: Position { line: 6, column: 12, }, end: Position { line: 6, column: 15, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "trivial", span: Span { start: Position { line: 6, column: 16, }, end: Position { line: 6, column: 23, }, }, }, ), ], default: None, }, ), ), attributes: [ Raw( PartRaw { content: "compare", span: Span { start: Position { line: 6, column: 25, }, end: Position { line: 6, column: 32, }, }, }, ), Raw( PartRaw { content: "min", span: Span { start: Position { line: 6, column: 33, }, end: Position { line: 6, column: 36, }, }, }, ), ], span: Span { start: Position { line: 4, column: 4, }, end: Position { line: 6, column: 37, }, }, }, ), Inherit( BindingInherit { from: Some( PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "lib", span: Span { start: Position { line: 7, column: 12, }, end: Position { line: 7, column: 15, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "attrsets", span: Span { start: Position { line: 7, column: 16, }, end: Position { line: 7, column: 24, }, }, }, ), ], default: None, }, ), ), attributes: [ Raw( PartRaw { content: "mapAttrs", span: Span { start: Position { line: 7, column: 26, }, end: Position { line: 7, column: 34, }, }, }, ), ], span: Span { start: Position { line: 4, column: 4, }, end: Position { line: 7, column: 35, }, }, }, ), ], target: Map( Map { recursive: true, bindings: [ Inherit( BindingInherit { from: Some( Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 11, column: 12, }, end: Position { line: 11, column: 20, }, }, }, ), ), attributes: [ Raw( PartRaw { content: "head", span: Span { start: Position { line: 11, column: 22, }, end: Position { line: 11, column: 26, }, }, }, ), Raw( PartRaw { content: "tail", span: Span { start: Position { line: 11, column: 27, }, end: Position { line: 11, column: 31, }, }, }, ), Raw( PartRaw { content: "length", span: Span { start: Position { line: 11, column: 32, }, end: Position { line: 11, column: 38, }, }, }, ), Raw( PartRaw { content: "isList", span: Span { start: Position { line: 11, column: 39, }, end: Position { line: 11, column: 45, }, }, }, ), Raw( PartRaw { content: "elemAt", span: Span { start: Position { line: 11, column: 46, }, end: Position { line: 11, column: 52, }, }, }, ), Raw( PartRaw { content: "concatLists", span: Span { start: Position { line: 11, column: 53, }, end: Position { line: 11, column: 64, }, }, }, ), Raw( PartRaw { content: "filter", span: Span { start: Position { line: 11, column: 65, }, end: Position { line: 11, column: 71, }, }, }, ), Raw( PartRaw { content: "elem", span: Span { start: Position { line: 11, column: 72, }, end: Position { line: 11, column: 76, }, }, }, ), Raw( PartRaw { content: "genList", span: Span { start: Position { line: 11, column: 77, }, end: Position { line: 11, column: 84, }, }, }, ), Raw( PartRaw { content: "map", span: Span { start: Position { line: 11, column: 85, }, end: Position { line: 11, column: 88, }, }, }, ), ], span: Span { start: Position { line: 9, column: 6, }, end: Position { line: 11, column: 89, }, }, }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "singleton", span: Span { start: Position { line: 23, column: 3, }, end: Position { line: 23, column: 12, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: List( List { elements: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 23, column: 19, }, end: Position { line: 23, column: 20, }, }, }, ), ], span: Span { start: Position { line: 23, column: 18, }, end: Position { line: 23, column: 21, }, }, }, ), span: Span { start: Position { line: 23, column: 15, }, end: Position { line: 23, column: 21, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "forEach", span: Span { start: Position { line: 36, column: 3, }, end: Position { line: 36, column: 10, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "xs", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "f", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "map", span: Span { start: Position { line: 36, column: 20, }, end: Position { line: 36, column: 23, }, }, }, ), arguments: [ Identifier( Identifier { id: "f", span: Span { start: Position { line: 36, column: 24, }, end: Position { line: 36, column: 25, }, }, }, ), Identifier( Identifier { id: "xs", span: Span { start: Position { line: 36, column: 26, }, end: Position { line: 36, column: 28, }, }, }, ), ], }, ), span: Span { start: Position { line: 36, column: 17, }, end: Position { line: 36, column: 28, }, }, }, ), span: Span { start: Position { line: 36, column: 13, }, end: Position { line: 36, column: 28, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "foldr", span: Span { start: Position { line: 53, column: 3, }, end: Position { line: 53, column: 8, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "op", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "nul", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "len", span: Span { start: Position { line: 55, column: 7, }, end: Position { line: 55, column: 10, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 55, column: 13, }, end: Position { line: 55, column: 19, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 55, column: 20, }, end: Position { line: 55, column: 24, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "fold'", span: Span { start: Position { line: 56, column: 7, }, end: Position { line: 56, column: 12, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 57, column: 12, }, end: Position { line: 57, column: 13, }, }, }, ), operator: EqualTo, right: Identifier( Identifier { id: "len", span: Span { start: Position { line: 57, column: 17, }, end: Position { line: 57, column: 20, }, }, }, ), }, ), then: Identifier( Identifier { id: "nul", span: Span { start: Position { line: 58, column: 14, }, end: Position { line: 58, column: 17, }, }, }, ), else_: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "op", span: Span { start: Position { line: 59, column: 14, }, end: Position { line: 59, column: 16, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 59, column: 18, }, end: Position { line: 59, column: 24, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 59, column: 25, }, end: Position { line: 59, column: 29, }, }, }, ), Identifier( Identifier { id: "n", span: Span { start: Position { line: 59, column: 30, }, end: Position { line: 59, column: 31, }, }, }, ), ], }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "fold'", span: Span { start: Position { line: 59, column: 34, }, end: Position { line: 59, column: 39, }, }, }, ), arguments: [ BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 59, column: 41, }, end: Position { line: 59, column: 42, }, }, }, ), operator: Addition, right: Integer( Integer { value: "1", span: Span { start: Position { line: 59, column: 45, }, end: Position { line: 59, column: 46, }, }, }, ), }, ), ], }, ), ], }, ), span: Span { start: Position { line: 57, column: 9, }, end: Position { line: 59, column: 48, }, }, }, ), span: Span { start: Position { line: 56, column: 15, }, end: Position { line: 59, column: 48, }, }, }, ), }, ), ], target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "fold'", span: Span { start: Position { line: 60, column: 8, }, end: Position { line: 60, column: 13, }, }, }, ), arguments: [ Integer( Integer { value: "0", span: Span { start: Position { line: 60, column: 14, }, end: Position { line: 60, column: 15, }, }, }, ), ], }, ), span: Span { start: Position { line: 54, column: 5, }, end: Position { line: 60, column: 15, }, }, }, ), span: Span { start: Position { line: 53, column: 20, }, end: Position { line: 60, column: 15, }, }, }, ), span: Span { start: Position { line: 53, column: 15, }, end: Position { line: 60, column: 15, }, }, }, ), span: Span { start: Position { line: 53, column: 11, }, end: Position { line: 60, column: 15, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "fold", span: Span { start: Position { line: 64, column: 3, }, end: Position { line: 64, column: 7, }, }, }, ), ], to: Identifier( Identifier { id: "foldr", span: Span { start: Position { line: 64, column: 10, }, end: Position { line: 64, column: 15, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "foldl", span: Span { start: Position { line: 81, column: 3, }, end: Position { line: 81, column: 8, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "op", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "nul", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "foldl'", span: Span { start: Position { line: 83, column: 7, }, end: Position { line: 83, column: 13, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 84, column: 12, }, end: Position { line: 84, column: 13, }, }, }, ), operator: EqualTo, right: UnaryOperation( UnaryOperation { operator: Negate, operand: Integer( Integer { value: "1", span: Span { start: Position { line: 84, column: 18, }, end: Position { line: 84, column: 19, }, }, }, ), span: Span { start: Position { line: 84, column: 17, }, end: Position { line: 84, column: 19, }, }, }, ), }, ), then: Identifier( Identifier { id: "nul", span: Span { start: Position { line: 85, column: 14, }, end: Position { line: 85, column: 17, }, }, }, ), else_: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "op", span: Span { start: Position { line: 86, column: 14, }, end: Position { line: 86, column: 16, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldl'", span: Span { start: Position { line: 86, column: 18, }, end: Position { line: 86, column: 24, }, }, }, ), arguments: [ BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 86, column: 26, }, end: Position { line: 86, column: 27, }, }, }, ), operator: Subtraction, right: Integer( Integer { value: "1", span: Span { start: Position { line: 86, column: 30, }, end: Position { line: 86, column: 31, }, }, }, ), }, ), ], }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 86, column: 35, }, end: Position { line: 86, column: 41, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 86, column: 42, }, end: Position { line: 86, column: 46, }, }, }, ), Identifier( Identifier { id: "n", span: Span { start: Position { line: 86, column: 47, }, end: Position { line: 86, column: 48, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 84, column: 9, }, end: Position { line: 86, column: 49, }, }, }, ), span: Span { start: Position { line: 83, column: 16, }, end: Position { line: 86, column: 49, }, }, }, ), }, ), ], target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldl'", span: Span { start: Position { line: 87, column: 8, }, end: Position { line: 87, column: 14, }, }, }, ), arguments: [ BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 87, column: 16, }, end: Position { line: 87, column: 22, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 87, column: 23, }, end: Position { line: 87, column: 27, }, }, }, ), ], }, ), operator: Subtraction, right: Integer( Integer { value: "1", span: Span { start: Position { line: 87, column: 30, }, end: Position { line: 87, column: 31, }, }, }, ), }, ), ], }, ), span: Span { start: Position { line: 82, column: 5, }, end: Position { line: 87, column: 32, }, }, }, ), span: Span { start: Position { line: 81, column: 20, }, end: Position { line: 87, column: 32, }, }, }, ), span: Span { start: Position { line: 81, column: 15, }, end: Position { line: 87, column: 32, }, }, }, ), span: Span { start: Position { line: 81, column: 11, }, end: Position { line: 87, column: 32, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "foldl'", span: Span { start: Position { line: 97, column: 3, }, end: Position { line: 97, column: 9, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 97, column: 12, }, end: Position { line: 97, column: 20, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "foldl'", span: Span { start: Position { line: 97, column: 21, }, end: Position { line: 97, column: 27, }, }, }, ), ], default: Some( Identifier( Identifier { id: "foldl", span: Span { start: Position { line: 97, column: 31, }, end: Position { line: 97, column: 36, }, }, }, ), ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "imap0", span: Span { start: Position { line: 107, column: 3, }, end: Position { line: 107, column: 8, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "f", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "genList", span: Span { start: Position { line: 107, column: 20, }, end: Position { line: 107, column: 27, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "f", span: Span { start: Position { line: 107, column: 32, }, end: Position { line: 107, column: 33, }, }, }, ), arguments: [ Identifier( Identifier { id: "n", span: Span { start: Position { line: 107, column: 34, }, end: Position { line: 107, column: 35, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 107, column: 37, }, end: Position { line: 107, column: 43, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 107, column: 44, }, end: Position { line: 107, column: 48, }, }, }, ), Identifier( Identifier { id: "n", span: Span { start: Position { line: 107, column: 49, }, end: Position { line: 107, column: 50, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 107, column: 29, }, end: Position { line: 107, column: 51, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 107, column: 54, }, end: Position { line: 107, column: 60, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 107, column: 61, }, end: Position { line: 107, column: 65, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 107, column: 14, }, end: Position { line: 107, column: 66, }, }, }, ), span: Span { start: Position { line: 107, column: 11, }, end: Position { line: 107, column: 66, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "imap1", span: Span { start: Position { line: 117, column: 3, }, end: Position { line: 117, column: 8, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "f", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "genList", span: Span { start: Position { line: 117, column: 20, }, end: Position { line: 117, column: 27, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "f", span: Span { start: Position { line: 117, column: 32, }, end: Position { line: 117, column: 33, }, }, }, ), arguments: [ BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 117, column: 35, }, end: Position { line: 117, column: 36, }, }, }, ), operator: Addition, right: Integer( Integer { value: "1", span: Span { start: Position { line: 117, column: 39, }, end: Position { line: 117, column: 40, }, }, }, ), }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 117, column: 43, }, end: Position { line: 117, column: 49, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 117, column: 50, }, end: Position { line: 117, column: 54, }, }, }, ), Identifier( Identifier { id: "n", span: Span { start: Position { line: 117, column: 55, }, end: Position { line: 117, column: 56, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 117, column: 29, }, end: Position { line: 117, column: 57, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 117, column: 60, }, end: Position { line: 117, column: 66, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 117, column: 67, }, end: Position { line: 117, column: 71, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 117, column: 14, }, end: Position { line: 117, column: 72, }, }, }, ), span: Span { start: Position { line: 117, column: 11, }, end: Position { line: 117, column: 72, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "concatMap", span: Span { start: Position { line: 127, column: 3, }, end: Position { line: 127, column: 12, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 127, column: 15, }, end: Position { line: 127, column: 23, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "concatMap", span: Span { start: Position { line: 127, column: 24, }, end: Position { line: 127, column: 33, }, }, }, ), ], default: Some( Function( Function { head: Simple( FunctionHeadSimple { identifier: "f", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "concatLists", span: Span { start: Position { line: 127, column: 47, }, end: Position { line: 127, column: 58, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "map", span: Span { start: Position { line: 127, column: 60, }, end: Position { line: 127, column: 63, }, }, }, ), arguments: [ Identifier( Identifier { id: "f", span: Span { start: Position { line: 127, column: 64, }, end: Position { line: 127, column: 65, }, }, }, ), Identifier( Identifier { id: "list", span: Span { start: Position { line: 127, column: 66, }, end: Position { line: 127, column: 70, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 127, column: 41, }, end: Position { line: 127, column: 71, }, }, }, ), span: Span { start: Position { line: 127, column: 38, }, end: Position { line: 127, column: 71, }, }, }, ), ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "flatten", span: Span { start: Position { line: 138, column: 3, }, end: Position { line: 138, column: 10, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "isList", span: Span { start: Position { line: 139, column: 8, }, end: Position { line: 139, column: 14, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 139, column: 15, }, end: Position { line: 139, column: 16, }, }, }, ), ], }, ), then: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "concatMap", span: Span { start: Position { line: 140, column: 10, }, end: Position { line: 140, column: 19, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "y", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "flatten", span: Span { start: Position { line: 140, column: 24, }, end: Position { line: 140, column: 31, }, }, }, ), arguments: [ Identifier( Identifier { id: "y", span: Span { start: Position { line: 140, column: 32, }, end: Position { line: 140, column: 33, }, }, }, ), ], }, ), span: Span { start: Position { line: 140, column: 21, }, end: Position { line: 140, column: 33, }, }, }, ), Identifier( Identifier { id: "x", span: Span { start: Position { line: 140, column: 35, }, end: Position { line: 140, column: 36, }, }, }, ), ], }, ), else_: List( List { elements: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 141, column: 11, }, end: Position { line: 141, column: 12, }, }, }, ), ], span: Span { start: Position { line: 141, column: 10, }, end: Position { line: 141, column: 13, }, }, }, ), span: Span { start: Position { line: 139, column: 5, }, end: Position { line: 141, column: 13, }, }, }, ), span: Span { start: Position { line: 138, column: 13, }, end: Position { line: 141, column: 13, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "remove", span: Span { start: Position { line: 151, column: 3, }, end: Position { line: 151, column: 9, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "e", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "filter", span: Span { start: Position { line: 153, column: 8, }, end: Position { line: 153, column: 14, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "x", span: Span { start: Position { line: 153, column: 19, }, end: Position { line: 153, column: 20, }, }, }, ), operator: NotEqualTo, right: Identifier( Identifier { id: "e", span: Span { start: Position { line: 153, column: 24, }, end: Position { line: 153, column: 25, }, }, }, ), }, ), span: Span { start: Position { line: 153, column: 16, }, end: Position { line: 153, column: 25, }, }, }, ), ], }, ), span: Span { start: Position { line: 153, column: 5, }, end: Position { line: 153, column: 26, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "findSingle", span: Span { start: Position { line: 169, column: 3, }, end: Position { line: 169, column: 13, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "default", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "multiple", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "found", span: Span { start: Position { line: 178, column: 9, }, end: Position { line: 178, column: 14, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "filter", span: Span { start: Position { line: 178, column: 17, }, end: Position { line: 178, column: 23, }, }, }, ), arguments: [ Identifier( Identifier { id: "pred", span: Span { start: Position { line: 178, column: 24, }, end: Position { line: 178, column: 28, }, }, }, ), Identifier( Identifier { id: "list", span: Span { start: Position { line: 178, column: 29, }, end: Position { line: 178, column: 33, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "len", span: Span { start: Position { line: 178, column: 35, }, end: Position { line: 178, column: 38, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 178, column: 41, }, end: Position { line: 178, column: 47, }, }, }, ), arguments: [ Identifier( Identifier { id: "found", span: Span { start: Position { line: 178, column: 48, }, end: Position { line: 178, column: 53, }, }, }, ), ], }, ), }, ), ], target: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "len", span: Span { start: Position { line: 179, column: 11, }, end: Position { line: 179, column: 14, }, }, }, ), operator: EqualTo, right: Integer( Integer { value: "0", span: Span { start: Position { line: 179, column: 18, }, end: Position { line: 179, column: 19, }, }, }, ), }, ), then: Identifier( Identifier { id: "default", span: Span { start: Position { line: 179, column: 25, }, end: Position { line: 179, column: 32, }, }, }, ), else_: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "len", span: Span { start: Position { line: 180, column: 15, }, end: Position { line: 180, column: 18, }, }, }, ), operator: NotEqualTo, right: Integer( Integer { value: "1", span: Span { start: Position { line: 180, column: 22, }, end: Position { line: 180, column: 23, }, }, }, ), }, ), then: Identifier( Identifier { id: "multiple", span: Span { start: Position { line: 180, column: 29, }, end: Position { line: 180, column: 37, }, }, }, ), else_: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 181, column: 12, }, end: Position { line: 181, column: 16, }, }, }, ), arguments: [ Identifier( Identifier { id: "found", span: Span { start: Position { line: 181, column: 17, }, end: Position { line: 181, column: 22, }, }, }, ), ], }, ), span: Span { start: Position { line: 180, column: 12, }, end: Position { line: 181, column: 22, }, }, }, ), span: Span { start: Position { line: 179, column: 8, }, end: Position { line: 181, column: 22, }, }, }, ), span: Span { start: Position { line: 178, column: 5, }, end: Position { line: 181, column: 22, }, }, }, ), span: Span { start: Position { line: 177, column: 5, }, end: Position { line: 181, column: 22, }, }, }, ), span: Span { start: Position { line: 175, column: 5, }, end: Position { line: 181, column: 22, }, }, }, ), span: Span { start: Position { line: 173, column: 5, }, end: Position { line: 181, column: 22, }, }, }, ), span: Span { start: Position { line: 171, column: 5, }, end: Position { line: 181, column: 22, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "findFirst", span: Span { start: Position { line: 194, column: 3, }, end: Position { line: 194, column: 12, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "default", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "found", span: Span { start: Position { line: 201, column: 9, }, end: Position { line: 201, column: 14, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "filter", span: Span { start: Position { line: 201, column: 17, }, end: Position { line: 201, column: 23, }, }, }, ), arguments: [ Identifier( Identifier { id: "pred", span: Span { start: Position { line: 201, column: 24, }, end: Position { line: 201, column: 28, }, }, }, ), Identifier( Identifier { id: "list", span: Span { start: Position { line: 201, column: 29, }, end: Position { line: 201, column: 33, }, }, }, ), ], }, ), }, ), ], target: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "found", span: Span { start: Position { line: 202, column: 11, }, end: Position { line: 202, column: 16, }, }, }, ), operator: EqualTo, right: List( List { elements: [], span: Span { start: Position { line: 202, column: 20, }, end: Position { line: 202, column: 22, }, }, }, ), }, ), then: Identifier( Identifier { id: "default", span: Span { start: Position { line: 202, column: 28, }, end: Position { line: 202, column: 35, }, }, }, ), else_: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 202, column: 41, }, end: Position { line: 202, column: 45, }, }, }, ), arguments: [ Identifier( Identifier { id: "found", span: Span { start: Position { line: 202, column: 46, }, end: Position { line: 202, column: 51, }, }, }, ), ], }, ), span: Span { start: Position { line: 202, column: 8, }, end: Position { line: 202, column: 51, }, }, }, ), span: Span { start: Position { line: 201, column: 5, }, end: Position { line: 202, column: 51, }, }, }, ), span: Span { start: Position { line: 200, column: 5, }, end: Position { line: 202, column: 51, }, }, }, ), span: Span { start: Position { line: 198, column: 5, }, end: Position { line: 202, column: 51, }, }, }, ), span: Span { start: Position { line: 196, column: 5, }, end: Position { line: 202, column: 51, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "any", span: Span { start: Position { line: 215, column: 3, }, end: Position { line: 215, column: 6, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 215, column: 9, }, end: Position { line: 215, column: 17, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "any", span: Span { start: Position { line: 215, column: 18, }, end: Position { line: 215, column: 21, }, }, }, ), ], default: Some( Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldr", span: Span { start: Position { line: 215, column: 32, }, end: Position { line: 215, column: 37, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "y", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "pred", span: Span { start: Position { line: 215, column: 48, }, end: Position { line: 215, column: 52, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 215, column: 53, }, end: Position { line: 215, column: 54, }, }, }, ), ], }, ), then: Identifier( Identifier { id: "true", span: Span { start: Position { line: 215, column: 60, }, end: Position { line: 215, column: 64, }, }, }, ), else_: Identifier( Identifier { id: "y", span: Span { start: Position { line: 215, column: 70, }, end: Position { line: 215, column: 71, }, }, }, ), span: Span { start: Position { line: 215, column: 45, }, end: Position { line: 215, column: 71, }, }, }, ), span: Span { start: Position { line: 215, column: 42, }, end: Position { line: 215, column: 71, }, }, }, ), span: Span { start: Position { line: 215, column: 39, }, end: Position { line: 215, column: 71, }, }, }, ), Identifier( Identifier { id: "false", span: Span { start: Position { line: 215, column: 73, }, end: Position { line: 215, column: 78, }, }, }, ), ], }, ), span: Span { start: Position { line: 215, column: 26, }, end: Position { line: 215, column: 78, }, }, }, ), ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "all", span: Span { start: Position { line: 228, column: 3, }, end: Position { line: 228, column: 6, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 228, column: 9, }, end: Position { line: 228, column: 17, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "all", span: Span { start: Position { line: 228, column: 18, }, end: Position { line: 228, column: 21, }, }, }, ), ], default: Some( Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldr", span: Span { start: Position { line: 228, column: 32, }, end: Position { line: 228, column: 37, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "y", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "pred", span: Span { start: Position { line: 228, column: 48, }, end: Position { line: 228, column: 52, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 228, column: 53, }, end: Position { line: 228, column: 54, }, }, }, ), ], }, ), then: Identifier( Identifier { id: "y", span: Span { start: Position { line: 228, column: 60, }, end: Position { line: 228, column: 61, }, }, }, ), else_: Identifier( Identifier { id: "false", span: Span { start: Position { line: 228, column: 67, }, end: Position { line: 228, column: 72, }, }, }, ), span: Span { start: Position { line: 228, column: 45, }, end: Position { line: 228, column: 72, }, }, }, ), span: Span { start: Position { line: 228, column: 42, }, end: Position { line: 228, column: 72, }, }, }, ), span: Span { start: Position { line: 228, column: 39, }, end: Position { line: 228, column: 72, }, }, }, ), Identifier( Identifier { id: "true", span: Span { start: Position { line: 228, column: 74, }, end: Position { line: 228, column: 78, }, }, }, ), ], }, ), span: Span { start: Position { line: 228, column: 26, }, end: Position { line: 228, column: 78, }, }, }, ), ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "count", span: Span { start: Position { line: 239, column: 3, }, end: Position { line: 239, column: 8, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldl'", span: Span { start: Position { line: 241, column: 11, }, end: Position { line: 241, column: 17, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "c", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "pred", span: Span { start: Position { line: 241, column: 28, }, end: Position { line: 241, column: 32, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 241, column: 33, }, end: Position { line: 241, column: 34, }, }, }, ), ], }, ), then: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "c", span: Span { start: Position { line: 241, column: 40, }, end: Position { line: 241, column: 41, }, }, }, ), operator: Addition, right: Integer( Integer { value: "1", span: Span { start: Position { line: 241, column: 44, }, end: Position { line: 241, column: 45, }, }, }, ), }, ), else_: Identifier( Identifier { id: "c", span: Span { start: Position { line: 241, column: 51, }, end: Position { line: 241, column: 52, }, }, }, ), span: Span { start: Position { line: 241, column: 25, }, end: Position { line: 241, column: 52, }, }, }, ), span: Span { start: Position { line: 241, column: 22, }, end: Position { line: 241, column: 52, }, }, }, ), span: Span { start: Position { line: 241, column: 19, }, end: Position { line: 241, column: 52, }, }, }, ), Integer( Integer { value: "0", span: Span { start: Position { line: 241, column: 54, }, end: Position { line: 241, column: 55, }, }, }, ), ], }, ), span: Span { start: Position { line: 241, column: 5, }, end: Position { line: 241, column: 55, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "optional", span: Span { start: Position { line: 255, column: 3, }, end: Position { line: 255, column: 11, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "cond", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "elem", }, ), body: IfThenElse( IfThenElse { predicate: Identifier( Identifier { id: "cond", span: Span { start: Position { line: 255, column: 29, }, end: Position { line: 255, column: 33, }, }, }, ), then: List( List { elements: [ Identifier( Identifier { id: "elem", span: Span { start: Position { line: 255, column: 40, }, end: Position { line: 255, column: 44, }, }, }, ), ], span: Span { start: Position { line: 255, column: 39, }, end: Position { line: 255, column: 45, }, }, }, ), else_: List( List { elements: [], span: Span { start: Position { line: 255, column: 51, }, end: Position { line: 255, column: 53, }, }, }, ), span: Span { start: Position { line: 255, column: 26, }, end: Position { line: 255, column: 53, }, }, }, ), span: Span { start: Position { line: 255, column: 20, }, end: Position { line: 255, column: 53, }, }, }, ), span: Span { start: Position { line: 255, column: 14, }, end: Position { line: 255, column: 53, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "optionals", span: Span { start: Position { line: 267, column: 3, }, end: Position { line: 267, column: 12, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "cond", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "elems", }, ), body: IfThenElse( IfThenElse { predicate: Identifier( Identifier { id: "cond", span: Span { start: Position { line: 271, column: 15, }, end: Position { line: 271, column: 19, }, }, }, ), then: Identifier( Identifier { id: "elems", span: Span { start: Position { line: 271, column: 25, }, end: Position { line: 271, column: 30, }, }, }, ), else_: List( List { elements: [], span: Span { start: Position { line: 271, column: 36, }, end: Position { line: 271, column: 38, }, }, }, ), span: Span { start: Position { line: 271, column: 12, }, end: Position { line: 271, column: 38, }, }, }, ), span: Span { start: Position { line: 271, column: 5, }, end: Position { line: 271, column: 38, }, }, }, ), span: Span { start: Position { line: 269, column: 5, }, end: Position { line: 271, column: 38, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "toList", span: Span { start: Position { line: 284, column: 3, }, end: Position { line: 284, column: 9, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "isList", span: Span { start: Position { line: 284, column: 18, }, end: Position { line: 284, column: 24, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 284, column: 25, }, end: Position { line: 284, column: 26, }, }, }, ), ], }, ), then: Identifier( Identifier { id: "x", span: Span { start: Position { line: 284, column: 32, }, end: Position { line: 284, column: 33, }, }, }, ), else_: List( List { elements: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 284, column: 40, }, end: Position { line: 284, column: 41, }, }, }, ), ], span: Span { start: Position { line: 284, column: 39, }, end: Position { line: 284, column: 42, }, }, }, ), span: Span { start: Position { line: 284, column: 15, }, end: Position { line: 284, column: 42, }, }, }, ), span: Span { start: Position { line: 284, column: 12, }, end: Position { line: 284, column: 42, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "range", span: Span { start: Position { line: 296, column: 3, }, end: Position { line: 296, column: 8, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "first", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "last", }, ), body: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "first", span: Span { start: Position { line: 301, column: 8, }, end: Position { line: 301, column: 13, }, }, }, ), operator: GreaterThan, right: Identifier( Identifier { id: "last", span: Span { start: Position { line: 301, column: 16, }, end: Position { line: 301, column: 20, }, }, }, ), }, ), then: List( List { elements: [], span: Span { start: Position { line: 302, column: 7, }, end: Position { line: 302, column: 9, }, }, }, ), else_: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "genList", span: Span { start: Position { line: 304, column: 7, }, end: Position { line: 304, column: 14, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "first", span: Span { start: Position { line: 304, column: 19, }, end: Position { line: 304, column: 24, }, }, }, ), operator: Addition, right: Identifier( Identifier { id: "n", span: Span { start: Position { line: 304, column: 27, }, end: Position { line: 304, column: 28, }, }, }, ), }, ), span: Span { start: Position { line: 304, column: 16, }, end: Position { line: 304, column: 28, }, }, }, ), BinaryOperation( BinaryOperation { left: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "last", span: Span { start: Position { line: 304, column: 31, }, end: Position { line: 304, column: 35, }, }, }, ), operator: Subtraction, right: Identifier( Identifier { id: "first", span: Span { start: Position { line: 304, column: 38, }, end: Position { line: 304, column: 43, }, }, }, ), }, ), operator: Addition, right: Integer( Integer { value: "1", span: Span { start: Position { line: 304, column: 46, }, end: Position { line: 304, column: 47, }, }, }, ), }, ), ], }, ), span: Span { start: Position { line: 301, column: 5, }, end: Position { line: 304, column: 48, }, }, }, ), span: Span { start: Position { line: 300, column: 5, }, end: Position { line: 304, column: 48, }, }, }, ), span: Span { start: Position { line: 298, column: 5, }, end: Position { line: 304, column: 48, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "partition", span: Span { start: Position { line: 315, column: 3, }, end: Position { line: 315, column: 12, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 315, column: 15, }, end: Position { line: 315, column: 23, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "partition", span: Span { start: Position { line: 315, column: 24, }, end: Position { line: 315, column: 33, }, }, }, ), ], default: Some( Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldr", span: Span { start: Position { line: 316, column: 5, }, end: Position { line: 316, column: 10, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "h", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "t", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "pred", span: Span { start: Position { line: 317, column: 10, }, end: Position { line: 317, column: 14, }, }, }, ), arguments: [ Identifier( Identifier { id: "h", span: Span { start: Position { line: 317, column: 15, }, end: Position { line: 317, column: 16, }, }, }, ), ], }, ), then: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 318, column: 14, }, end: Position { line: 318, column: 19, }, }, }, ), ], to: BinaryOperation( BinaryOperation { left: List( List { elements: [ Identifier( Identifier { id: "h", span: Span { start: Position { line: 318, column: 23, }, end: Position { line: 318, column: 24, }, }, }, ), ], span: Span { start: Position { line: 318, column: 22, }, end: Position { line: 318, column: 25, }, }, }, ), operator: Concatenation, right: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "t", span: Span { start: Position { line: 318, column: 29, }, end: Position { line: 318, column: 30, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 318, column: 31, }, end: Position { line: 318, column: 36, }, }, }, ), ], default: None, }, ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "wrong", span: Span { start: Position { line: 318, column: 38, }, end: Position { line: 318, column: 43, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "t", span: Span { start: Position { line: 318, column: 46, }, end: Position { line: 318, column: 47, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "wrong", span: Span { start: Position { line: 318, column: 48, }, end: Position { line: 318, column: 53, }, }, }, ), ], default: None, }, ), }, ), ], span: Span { start: Position { line: 318, column: 12, }, end: Position { line: 318, column: 56, }, }, }, ), else_: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 319, column: 14, }, end: Position { line: 319, column: 19, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "t", span: Span { start: Position { line: 319, column: 22, }, end: Position { line: 319, column: 23, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 319, column: 24, }, end: Position { line: 319, column: 29, }, }, }, ), ], default: None, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "wrong", span: Span { start: Position { line: 319, column: 31, }, end: Position { line: 319, column: 36, }, }, }, ), ], to: BinaryOperation( BinaryOperation { left: List( List { elements: [ Identifier( Identifier { id: "h", span: Span { start: Position { line: 319, column: 40, }, end: Position { line: 319, column: 41, }, }, }, ), ], span: Span { start: Position { line: 319, column: 39, }, end: Position { line: 319, column: 42, }, }, }, ), operator: Concatenation, right: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "t", span: Span { start: Position { line: 319, column: 46, }, end: Position { line: 319, column: 47, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "wrong", span: Span { start: Position { line: 319, column: 48, }, end: Position { line: 319, column: 53, }, }, }, ), ], default: None, }, ), }, ), }, ), ], span: Span { start: Position { line: 319, column: 12, }, end: Position { line: 319, column: 56, }, }, }, ), span: Span { start: Position { line: 317, column: 7, }, end: Position { line: 319, column: 56, }, }, }, ), span: Span { start: Position { line: 316, column: 15, }, end: Position { line: 319, column: 56, }, }, }, ), span: Span { start: Position { line: 316, column: 12, }, end: Position { line: 319, column: 56, }, }, }, ), Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 320, column: 9, }, end: Position { line: 320, column: 14, }, }, }, ), ], to: List( List { elements: [], span: Span { start: Position { line: 320, column: 17, }, end: Position { line: 320, column: 19, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "wrong", span: Span { start: Position { line: 320, column: 21, }, end: Position { line: 320, column: 26, }, }, }, ), ], to: List( List { elements: [], span: Span { start: Position { line: 320, column: 29, }, end: Position { line: 320, column: 31, }, }, }, ), }, ), ], span: Span { start: Position { line: 320, column: 7, }, end: Position { line: 320, column: 34, }, }, }, ), ], }, ), span: Span { start: Position { line: 315, column: 38, }, end: Position { line: 320, column: 34, }, }, }, ), ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "groupBy'", span: Span { start: Position { line: 344, column: 3, }, end: Position { line: 344, column: 11, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "op", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "nul", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "lst", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "mapAttrs", span: Span { start: Position { line: 344, column: 34, }, end: Position { line: 344, column: 42, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "name", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldl", span: Span { start: Position { line: 344, column: 50, }, end: Position { line: 344, column: 55, }, }, }, ), arguments: [ Identifier( Identifier { id: "op", span: Span { start: Position { line: 344, column: 56, }, end: Position { line: 344, column: 58, }, }, }, ), Identifier( Identifier { id: "nul", span: Span { start: Position { line: 344, column: 59, }, end: Position { line: 344, column: 62, }, }, }, ), ], }, ), span: Span { start: Position { line: 344, column: 44, }, end: Position { line: 344, column: 62, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "groupBy", span: Span { start: Position { line: 344, column: 65, }, end: Position { line: 344, column: 72, }, }, }, ), arguments: [ Identifier( Identifier { id: "pred", span: Span { start: Position { line: 344, column: 73, }, end: Position { line: 344, column: 77, }, }, }, ), Identifier( Identifier { id: "lst", span: Span { start: Position { line: 344, column: 78, }, end: Position { line: 344, column: 81, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 344, column: 29, }, end: Position { line: 344, column: 82, }, }, }, ), span: Span { start: Position { line: 344, column: 23, }, end: Position { line: 344, column: 82, }, }, }, ), span: Span { start: Position { line: 344, column: 18, }, end: Position { line: 344, column: 82, }, }, }, ), span: Span { start: Position { line: 344, column: 14, }, end: Position { line: 344, column: 82, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "groupBy", span: Span { start: Position { line: 346, column: 3, }, end: Position { line: 346, column: 10, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 346, column: 13, }, end: Position { line: 346, column: 21, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "groupBy", span: Span { start: Position { line: 346, column: 22, }, end: Position { line: 346, column: 29, }, }, }, ), ], default: Some( Function( Function { head: Simple( FunctionHeadSimple { identifier: "pred", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldl'", span: Span { start: Position { line: 347, column: 11, }, end: Position { line: 347, column: 17, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "r", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "e", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "key", span: Span { start: Position { line: 349, column: 10, }, end: Position { line: 349, column: 13, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "pred", span: Span { start: Position { line: 349, column: 16, }, end: Position { line: 349, column: 20, }, }, }, ), arguments: [ Identifier( Identifier { id: "e", span: Span { start: Position { line: 349, column: 21, }, end: Position { line: 349, column: 22, }, }, }, ), ], }, ), }, ), ], target: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "r", span: Span { start: Position { line: 351, column: 10, }, end: Position { line: 351, column: 11, }, }, }, ), operator: Update, right: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Interpolation( PartInterpolation { expression: Identifier( Identifier { id: "key", span: Span { start: Position { line: 351, column: 19, }, end: Position { line: 351, column: 22, }, }, }, ), }, ), ], to: BinaryOperation( BinaryOperation { left: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "r", span: Span { start: Position { line: 351, column: 27, }, end: Position { line: 351, column: 28, }, }, }, ), attribute_path: [ Interpolation( PartInterpolation { expression: Identifier( Identifier { id: "key", span: Span { start: Position { line: 351, column: 31, }, end: Position { line: 351, column: 34, }, }, }, ), }, ), ], default: Some( List( List { elements: [], span: Span { start: Position { line: 351, column: 39, }, end: Position { line: 351, column: 41, }, }, }, ), ), }, ), operator: Concatenation, right: List( List { elements: [ Identifier( Identifier { id: "e", span: Span { start: Position { line: 351, column: 47, }, end: Position { line: 351, column: 48, }, }, }, ), ], span: Span { start: Position { line: 351, column: 46, }, end: Position { line: 351, column: 49, }, }, }, ), }, ), }, ), ], span: Span { start: Position { line: 351, column: 15, }, end: Position { line: 351, column: 52, }, }, }, ), }, ), span: Span { start: Position { line: 348, column: 8, }, end: Position { line: 351, column: 52, }, }, }, ), span: Span { start: Position { line: 347, column: 22, }, end: Position { line: 351, column: 52, }, }, }, ), span: Span { start: Position { line: 347, column: 19, }, end: Position { line: 351, column: 52, }, }, }, ), Map( Map { recursive: false, bindings: [], span: Span { start: Position { line: 352, column: 7, }, end: Position { line: 352, column: 9, }, }, }, ), ], }, ), span: Span { start: Position { line: 347, column: 5, }, end: Position { line: 352, column: 9, }, }, }, ), ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "zipListsWith", span: Span { start: Position { line: 364, column: 3, }, end: Position { line: 364, column: 15, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "f", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "fst", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "snd", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "genList", span: Span { start: Position { line: 371, column: 5, }, end: Position { line: 371, column: 12, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "f", span: Span { start: Position { line: 372, column: 11, }, end: Position { line: 372, column: 12, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 372, column: 14, }, end: Position { line: 372, column: 20, }, }, }, ), arguments: [ Identifier( Identifier { id: "fst", span: Span { start: Position { line: 372, column: 21, }, end: Position { line: 372, column: 24, }, }, }, ), Identifier( Identifier { id: "n", span: Span { start: Position { line: 372, column: 25, }, end: Position { line: 372, column: 26, }, }, }, ), ], }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 372, column: 29, }, end: Position { line: 372, column: 35, }, }, }, ), arguments: [ Identifier( Identifier { id: "snd", span: Span { start: Position { line: 372, column: 36, }, end: Position { line: 372, column: 39, }, }, }, ), Identifier( Identifier { id: "n", span: Span { start: Position { line: 372, column: 40, }, end: Position { line: 372, column: 41, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 372, column: 8, }, end: Position { line: 372, column: 42, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "min", span: Span { start: Position { line: 372, column: 45, }, end: Position { line: 372, column: 48, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 372, column: 50, }, end: Position { line: 372, column: 56, }, }, }, ), arguments: [ Identifier( Identifier { id: "fst", span: Span { start: Position { line: 372, column: 57, }, end: Position { line: 372, column: 60, }, }, }, ), ], }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 372, column: 63, }, end: Position { line: 372, column: 69, }, }, }, ), arguments: [ Identifier( Identifier { id: "snd", span: Span { start: Position { line: 372, column: 70, }, end: Position { line: 372, column: 73, }, }, }, ), ], }, ), ], }, ), ], }, ), span: Span { start: Position { line: 370, column: 5, }, end: Position { line: 372, column: 75, }, }, }, ), span: Span { start: Position { line: 368, column: 5, }, end: Position { line: 372, column: 75, }, }, }, ), span: Span { start: Position { line: 366, column: 5, }, end: Position { line: 372, column: 75, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "zipLists", span: Span { start: Position { line: 383, column: 3, }, end: Position { line: 383, column: 11, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "zipListsWith", span: Span { start: Position { line: 383, column: 14, }, end: Position { line: 383, column: 26, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "fst", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "snd", }, ), body: Map( Map { recursive: false, bindings: [ Inherit( BindingInherit { from: None, attributes: [ Raw( PartRaw { content: "fst", span: Span { start: Position { line: 383, column: 48, }, end: Position { line: 383, column: 51, }, }, }, ), Raw( PartRaw { content: "snd", span: Span { start: Position { line: 383, column: 52, }, end: Position { line: 383, column: 55, }, }, }, ), ], span: Span { start: Position { line: 383, column: 39, }, end: Position { line: 383, column: 56, }, }, }, ), ], span: Span { start: Position { line: 383, column: 38, }, end: Position { line: 383, column: 58, }, }, }, ), span: Span { start: Position { line: 383, column: 33, }, end: Position { line: 383, column: 58, }, }, }, ), span: Span { start: Position { line: 383, column: 28, }, end: Position { line: 383, column: 58, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "reverseList", span: Span { start: Position { line: 394, column: 3, }, end: Position { line: 394, column: 14, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "xs", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "l", span: Span { start: Position { line: 395, column: 9, }, end: Position { line: 395, column: 10, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 395, column: 13, }, end: Position { line: 395, column: 19, }, }, }, ), arguments: [ Identifier( Identifier { id: "xs", span: Span { start: Position { line: 395, column: 20, }, end: Position { line: 395, column: 22, }, }, }, ), ], }, ), }, ), ], target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "genList", span: Span { start: Position { line: 395, column: 27, }, end: Position { line: 395, column: 34, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 395, column: 39, }, end: Position { line: 395, column: 45, }, }, }, ), arguments: [ Identifier( Identifier { id: "xs", span: Span { start: Position { line: 395, column: 46, }, end: Position { line: 395, column: 48, }, }, }, ), BinaryOperation( BinaryOperation { left: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "l", span: Span { start: Position { line: 395, column: 50, }, end: Position { line: 395, column: 51, }, }, }, ), operator: Subtraction, right: Identifier( Identifier { id: "n", span: Span { start: Position { line: 395, column: 54, }, end: Position { line: 395, column: 55, }, }, }, ), }, ), operator: Subtraction, right: Integer( Integer { value: "1", span: Span { start: Position { line: 395, column: 58, }, end: Position { line: 395, column: 59, }, }, }, ), }, ), ], }, ), span: Span { start: Position { line: 395, column: 36, }, end: Position { line: 395, column: 60, }, }, }, ), Identifier( Identifier { id: "l", span: Span { start: Position { line: 395, column: 62, }, end: Position { line: 395, column: 63, }, }, }, ), ], }, ), span: Span { start: Position { line: 395, column: 5, }, end: Position { line: 395, column: 63, }, }, }, ), span: Span { start: Position { line: 394, column: 17, }, end: Position { line: 395, column: 63, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "listDfs", span: Span { start: Position { line: 416, column: 3, }, end: Position { line: 416, column: 10, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "stopOnCycles", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "before", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "dfs'", span: Span { start: Position { line: 418, column: 7, }, end: Position { line: 418, column: 11, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "us", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "visited", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "rest", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "c", span: Span { start: Position { line: 420, column: 11, }, end: Position { line: 420, column: 12, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "filter", span: Span { start: Position { line: 420, column: 15, }, end: Position { line: 420, column: 21, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "before", span: Span { start: Position { line: 420, column: 26, }, end: Position { line: 420, column: 32, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 420, column: 33, }, end: Position { line: 420, column: 34, }, }, }, ), Identifier( Identifier { id: "us", span: Span { start: Position { line: 420, column: 35, }, end: Position { line: 420, column: 37, }, }, }, ), ], }, ), span: Span { start: Position { line: 420, column: 23, }, end: Position { line: 420, column: 37, }, }, }, ), Identifier( Identifier { id: "visited", span: Span { start: Position { line: 420, column: 39, }, end: Position { line: 420, column: 46, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "b", span: Span { start: Position { line: 421, column: 11, }, end: Position { line: 421, column: 12, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "partition", span: Span { start: Position { line: 421, column: 15, }, end: Position { line: 421, column: 24, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "before", span: Span { start: Position { line: 421, column: 29, }, end: Position { line: 421, column: 35, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 421, column: 36, }, end: Position { line: 421, column: 37, }, }, }, ), Identifier( Identifier { id: "us", span: Span { start: Position { line: 421, column: 38, }, end: Position { line: 421, column: 40, }, }, }, ), ], }, ), span: Span { start: Position { line: 421, column: 26, }, end: Position { line: 421, column: 40, }, }, }, ), Identifier( Identifier { id: "rest", span: Span { start: Position { line: 421, column: 42, }, end: Position { line: 421, column: 46, }, }, }, ), ], }, ), }, ), ], target: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "stopOnCycles", span: Span { start: Position { line: 422, column: 15, }, end: Position { line: 422, column: 27, }, }, }, ), operator: LogicalAnd, right: BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 422, column: 32, }, end: Position { line: 422, column: 38, }, }, }, ), arguments: [ Identifier( Identifier { id: "c", span: Span { start: Position { line: 422, column: 39, }, end: Position { line: 422, column: 40, }, }, }, ), ], }, ), operator: GreaterThan, right: Integer( Integer { value: "0", span: Span { start: Position { line: 422, column: 43, }, end: Position { line: 422, column: 44, }, }, }, ), }, ), }, ), then: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "cycle", span: Span { start: Position { line: 423, column: 19, }, end: Position { line: 423, column: 24, }, }, }, ), ], to: Identifier( Identifier { id: "us", span: Span { start: Position { line: 423, column: 27, }, end: Position { line: 423, column: 29, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "loops", span: Span { start: Position { line: 423, column: 31, }, end: Position { line: 423, column: 36, }, }, }, ), ], to: Identifier( Identifier { id: "c", span: Span { start: Position { line: 423, column: 39, }, end: Position { line: 423, column: 40, }, }, }, ), }, ), Inherit( BindingInherit { from: None, attributes: [ Raw( PartRaw { content: "visited", span: Span { start: Position { line: 423, column: 50, }, end: Position { line: 423, column: 57, }, }, }, ), Raw( PartRaw { content: "rest", span: Span { start: Position { line: 423, column: 58, }, end: Position { line: 423, column: 62, }, }, }, ), ], span: Span { start: Position { line: 423, column: 18, }, end: Position { line: 423, column: 63, }, }, }, ), ], span: Span { start: Position { line: 423, column: 17, }, end: Position { line: 423, column: 65, }, }, }, ), else_: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 424, column: 20, }, end: Position { line: 424, column: 26, }, }, }, ), arguments: [ PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "b", span: Span { start: Position { line: 424, column: 27, }, end: Position { line: 424, column: 28, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 424, column: 29, }, end: Position { line: 424, column: 34, }, }, }, ), ], default: None, }, ), ], }, ), operator: EqualTo, right: Integer( Integer { value: "0", span: Span { start: Position { line: 424, column: 38, }, end: Position { line: 424, column: 39, }, }, }, ), }, ), then: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "minimal", span: Span { start: Position { line: 426, column: 24, }, end: Position { line: 426, column: 31, }, }, }, ), ], to: Identifier( Identifier { id: "us", span: Span { start: Position { line: 426, column: 34, }, end: Position { line: 426, column: 36, }, }, }, ), }, ), Inherit( BindingInherit { from: None, attributes: [ Raw( PartRaw { content: "visited", span: Span { start: Position { line: 426, column: 46, }, end: Position { line: 426, column: 53, }, }, }, ), Raw( PartRaw { content: "rest", span: Span { start: Position { line: 426, column: 54, }, end: Position { line: 426, column: 58, }, }, }, ), ], span: Span { start: Position { line: 426, column: 23, }, end: Position { line: 426, column: 59, }, }, }, ), ], span: Span { start: Position { line: 426, column: 22, }, end: Position { line: 426, column: 61, }, }, }, ), else_: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "dfs'", span: Span { start: Position { line: 428, column: 22, }, end: Position { line: 428, column: 26, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 428, column: 28, }, end: Position { line: 428, column: 32, }, }, }, ), arguments: [ PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "b", span: Span { start: Position { line: 428, column: 33, }, end: Position { line: 428, column: 34, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 428, column: 35, }, end: Position { line: 428, column: 40, }, }, }, ), ], default: None, }, ), ], }, ), BinaryOperation( BinaryOperation { left: List( List { elements: [ Identifier( Identifier { id: "us", span: Span { start: Position { line: 429, column: 30, }, end: Position { line: 429, column: 32, }, }, }, ), ], span: Span { start: Position { line: 429, column: 28, }, end: Position { line: 429, column: 34, }, }, }, ), operator: Concatenation, right: Identifier( Identifier { id: "visited", span: Span { start: Position { line: 429, column: 38, }, end: Position { line: 429, column: 45, }, }, }, ), }, ), BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "tail", span: Span { start: Position { line: 430, column: 28, }, end: Position { line: 430, column: 32, }, }, }, ), arguments: [ PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "b", span: Span { start: Position { line: 430, column: 33, }, end: Position { line: 430, column: 34, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 430, column: 35, }, end: Position { line: 430, column: 40, }, }, }, ), ], default: None, }, ), ], }, ), operator: Concatenation, right: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "b", span: Span { start: Position { line: 430, column: 44, }, end: Position { line: 430, column: 45, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "wrong", span: Span { start: Position { line: 430, column: 46, }, end: Position { line: 430, column: 51, }, }, }, ), ], default: None, }, ), }, ), ], }, ), span: Span { start: Position { line: 424, column: 17, }, end: Position { line: 430, column: 52, }, }, }, ), span: Span { start: Position { line: 422, column: 12, }, end: Position { line: 430, column: 52, }, }, }, ), span: Span { start: Position { line: 419, column: 9, }, end: Position { line: 430, column: 52, }, }, }, ), span: Span { start: Position { line: 418, column: 27, }, end: Position { line: 430, column: 52, }, }, }, ), span: Span { start: Position { line: 418, column: 18, }, end: Position { line: 430, column: 52, }, }, }, ), span: Span { start: Position { line: 418, column: 14, }, end: Position { line: 430, column: 52, }, }, }, ), }, ), ], target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "dfs'", span: Span { start: Position { line: 431, column: 8, }, end: Position { line: 431, column: 12, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 431, column: 14, }, end: Position { line: 431, column: 18, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 431, column: 19, }, end: Position { line: 431, column: 23, }, }, }, ), ], }, ), List( List { elements: [], span: Span { start: Position { line: 431, column: 25, }, end: Position { line: 431, column: 27, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "tail", span: Span { start: Position { line: 431, column: 29, }, end: Position { line: 431, column: 33, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 431, column: 34, }, end: Position { line: 431, column: 38, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 417, column: 5, }, end: Position { line: 431, column: 39, }, }, }, ), span: Span { start: Position { line: 416, column: 35, }, end: Position { line: 431, column: 39, }, }, }, ), span: Span { start: Position { line: 416, column: 27, }, end: Position { line: 431, column: 39, }, }, }, ), span: Span { start: Position { line: 416, column: 13, }, end: Position { line: 431, column: 39, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "toposort", span: Span { start: Position { line: 455, column: 3, }, end: Position { line: 455, column: 11, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "before", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "dfsthis", span: Span { start: Position { line: 457, column: 7, }, end: Position { line: 457, column: 14, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "listDfs", span: Span { start: Position { line: 457, column: 17, }, end: Position { line: 457, column: 24, }, }, }, ), arguments: [ Identifier( Identifier { id: "true", span: Span { start: Position { line: 457, column: 25, }, end: Position { line: 457, column: 29, }, }, }, ), Identifier( Identifier { id: "before", span: Span { start: Position { line: 457, column: 30, }, end: Position { line: 457, column: 36, }, }, }, ), Identifier( Identifier { id: "list", span: Span { start: Position { line: 457, column: 37, }, end: Position { line: 457, column: 41, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "toporest", span: Span { start: Position { line: 458, column: 7, }, end: Position { line: 458, column: 15, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "toposort", span: Span { start: Position { line: 458, column: 18, }, end: Position { line: 458, column: 26, }, }, }, ), arguments: [ Identifier( Identifier { id: "before", span: Span { start: Position { line: 458, column: 27, }, end: Position { line: 458, column: 33, }, }, }, ), BinaryOperation( BinaryOperation { left: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "dfsthis", span: Span { start: Position { line: 458, column: 35, }, end: Position { line: 458, column: 42, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "visited", span: Span { start: Position { line: 458, column: 43, }, end: Position { line: 458, column: 50, }, }, }, ), ], default: None, }, ), operator: Concatenation, right: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "dfsthis", span: Span { start: Position { line: 458, column: 54, }, end: Position { line: 458, column: 61, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "rest", span: Span { start: Position { line: 458, column: 62, }, end: Position { line: 458, column: 66, }, }, }, ), ], default: None, }, ), }, ), ], }, ), }, ), ], target: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 460, column: 10, }, end: Position { line: 460, column: 16, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 460, column: 17, }, end: Position { line: 460, column: 21, }, }, }, ), ], }, ), operator: LessThan, right: Integer( Integer { value: "2", span: Span { start: Position { line: 460, column: 24, }, end: Position { line: 460, column: 25, }, }, }, ), }, ), then: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "result", span: Span { start: Position { line: 462, column: 14, }, end: Position { line: 462, column: 20, }, }, }, ), ], to: Identifier( Identifier { id: "list", span: Span { start: Position { line: 462, column: 24, }, end: Position { line: 462, column: 28, }, }, }, ), }, ), ], span: Span { start: Position { line: 462, column: 12, }, end: Position { line: 462, column: 31, }, }, }, ), else_: IfThenElse( IfThenElse { predicate: HasAttribute( HasAttribute { expression: Identifier( Identifier { id: "dfsthis", span: Span { start: Position { line: 463, column: 15, }, end: Position { line: 463, column: 22, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "cycle", span: Span { start: Position { line: 463, column: 25, }, end: Position { line: 463, column: 30, }, }, }, ), ], }, ), then: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "cycle", span: Span { start: Position { line: 465, column: 19, }, end: Position { line: 465, column: 24, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "reverseList", span: Span { start: Position { line: 465, column: 27, }, end: Position { line: 465, column: 38, }, }, }, ), arguments: [ BinaryOperation( BinaryOperation { left: List( List { elements: [ PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "dfsthis", span: Span { start: Position { line: 465, column: 42, }, end: Position { line: 465, column: 49, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "cycle", span: Span { start: Position { line: 465, column: 50, }, end: Position { line: 465, column: 55, }, }, }, ), ], default: None, }, ), ], span: Span { start: Position { line: 465, column: 40, }, end: Position { line: 465, column: 57, }, }, }, ), operator: Concatenation, right: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "dfsthis", span: Span { start: Position { line: 465, column: 61, }, end: Position { line: 465, column: 68, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "visited", span: Span { start: Position { line: 465, column: 69, }, end: Position { line: 465, column: 76, }, }, }, ), ], default: None, }, ), }, ), ], }, ), }, ), Inherit( BindingInherit { from: Some( Identifier( Identifier { id: "dfsthis", span: Span { start: Position { line: 466, column: 28, }, end: Position { line: 466, column: 35, }, }, }, ), ), attributes: [ Raw( PartRaw { content: "loops", span: Span { start: Position { line: 466, column: 37, }, end: Position { line: 466, column: 42, }, }, }, ), ], span: Span { start: Position { line: 465, column: 18, }, end: Position { line: 466, column: 43, }, }, }, ), ], span: Span { start: Position { line: 465, column: 17, }, end: Position { line: 466, column: 45, }, }, }, ), else_: IfThenElse( IfThenElse { predicate: HasAttribute( HasAttribute { expression: Identifier( Identifier { id: "toporest", span: Span { start: Position { line: 467, column: 20, }, end: Position { line: 467, column: 28, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "cycle", span: Span { start: Position { line: 467, column: 31, }, end: Position { line: 467, column: 36, }, }, }, ), ], }, ), then: Identifier( Identifier { id: "toporest", span: Span { start: Position { line: 469, column: 22, }, end: Position { line: 469, column: 30, }, }, }, ), else_: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "result", span: Span { start: Position { line: 472, column: 24, }, end: Position { line: 472, column: 30, }, }, }, ), ], to: BinaryOperation( BinaryOperation { left: List( List { elements: [ PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "dfsthis", span: Span { start: Position { line: 472, column: 35, }, end: Position { line: 472, column: 42, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "minimal", span: Span { start: Position { line: 472, column: 43, }, end: Position { line: 472, column: 50, }, }, }, ), ], default: None, }, ), ], span: Span { start: Position { line: 472, column: 33, }, end: Position { line: 472, column: 52, }, }, }, ), operator: Concatenation, right: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "toporest", span: Span { start: Position { line: 472, column: 56, }, end: Position { line: 472, column: 64, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "result", span: Span { start: Position { line: 472, column: 65, }, end: Position { line: 472, column: 71, }, }, }, ), ], default: None, }, ), }, ), }, ), ], span: Span { start: Position { line: 472, column: 22, }, end: Position { line: 472, column: 74, }, }, }, ), span: Span { start: Position { line: 467, column: 17, }, end: Position { line: 472, column: 74, }, }, }, ), span: Span { start: Position { line: 463, column: 12, }, end: Position { line: 472, column: 74, }, }, }, ), span: Span { start: Position { line: 460, column: 7, }, end: Position { line: 472, column: 74, }, }, }, ), span: Span { start: Position { line: 456, column: 5, }, end: Position { line: 472, column: 74, }, }, }, ), span: Span { start: Position { line: 455, column: 22, }, end: Position { line: 472, column: 74, }, }, }, ), span: Span { start: Position { line: 455, column: 14, }, end: Position { line: 472, column: 74, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "sort", span: Span { start: Position { line: 483, column: 3, }, end: Position { line: 483, column: 7, }, }, }, ), ], to: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 483, column: 10, }, end: Position { line: 483, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "sort", span: Span { start: Position { line: 483, column: 19, }, end: Position { line: 483, column: 23, }, }, }, ), ], default: Some( Function( Function { head: Simple( FunctionHeadSimple { identifier: "strictLess", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "len", span: Span { start: Position { line: 486, column: 7, }, end: Position { line: 486, column: 10, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 486, column: 13, }, end: Position { line: 486, column: 19, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 486, column: 20, }, end: Position { line: 486, column: 24, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "first", span: Span { start: Position { line: 487, column: 7, }, end: Position { line: 487, column: 12, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 487, column: 15, }, end: Position { line: 487, column: 19, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 487, column: 20, }, end: Position { line: 487, column: 24, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "pivot'", span: Span { start: Position { line: 488, column: 7, }, end: Position { line: 488, column: 13, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: Function( Function { head: Destructured( FunctionHeadDestructured { ellipsis: false, identifier: LeftAt( "acc", ), arguments: [ FunctionHeadDestructuredArgument { identifier: "left", default: None, }, FunctionHeadDestructuredArgument { identifier: "right", default: None, }, ], }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "el", span: Span { start: Position { line: 488, column: 44, }, end: Position { line: 488, column: 46, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 488, column: 49, }, end: Position { line: 488, column: 55, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 488, column: 56, }, end: Position { line: 488, column: 60, }, }, }, ), Identifier( Identifier { id: "n", span: Span { start: Position { line: 488, column: 61, }, end: Position { line: 488, column: 62, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "next", span: Span { start: Position { line: 488, column: 64, }, end: Position { line: 488, column: 68, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "pivot'", span: Span { start: Position { line: 488, column: 71, }, end: Position { line: 488, column: 77, }, }, }, ), arguments: [ BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 488, column: 79, }, end: Position { line: 488, column: 80, }, }, }, ), operator: Addition, right: Integer( Integer { value: "1", span: Span { start: Position { line: 488, column: 83, }, end: Position { line: 488, column: 84, }, }, }, ), }, ), ], }, ), }, ), ], target: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 489, column: 12, }, end: Position { line: 489, column: 13, }, }, }, ), operator: EqualTo, right: Identifier( Identifier { id: "len", span: Span { start: Position { line: 489, column: 17, }, end: Position { line: 489, column: 20, }, }, }, ), }, ), then: Identifier( Identifier { id: "acc", span: Span { start: Position { line: 490, column: 16, }, end: Position { line: 490, column: 19, }, }, }, ), else_: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "strictLess", span: Span { start: Position { line: 491, column: 17, }, end: Position { line: 491, column: 27, }, }, }, ), arguments: [ Identifier( Identifier { id: "first", span: Span { start: Position { line: 491, column: 28, }, end: Position { line: 491, column: 33, }, }, }, ), Identifier( Identifier { id: "el", span: Span { start: Position { line: 491, column: 34, }, end: Position { line: 491, column: 36, }, }, }, ), ], }, ), then: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "next", span: Span { start: Position { line: 492, column: 16, }, end: Position { line: 492, column: 20, }, }, }, ), arguments: [ Map( Map { recursive: false, bindings: [ Inherit( BindingInherit { from: None, attributes: [ Raw( PartRaw { content: "left", span: Span { start: Position { line: 492, column: 31, }, end: Position { line: 492, column: 35, }, }, }, ), ], span: Span { start: Position { line: 492, column: 22, }, end: Position { line: 492, column: 36, }, }, }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 492, column: 37, }, end: Position { line: 492, column: 42, }, }, }, ), ], to: BinaryOperation( BinaryOperation { left: List( List { elements: [ Identifier( Identifier { id: "el", span: Span { start: Position { line: 492, column: 47, }, end: Position { line: 492, column: 49, }, }, }, ), ], span: Span { start: Position { line: 492, column: 45, }, end: Position { line: 492, column: 51, }, }, }, ), operator: Concatenation, right: Identifier( Identifier { id: "right", span: Span { start: Position { line: 492, column: 55, }, end: Position { line: 492, column: 60, }, }, }, ), }, ), }, ), ], span: Span { start: Position { line: 492, column: 21, }, end: Position { line: 492, column: 63, }, }, }, ), ], }, ), else_: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "next", span: Span { start: Position { line: 494, column: 11, }, end: Position { line: 494, column: 15, }, }, }, ), arguments: [ Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "left", span: Span { start: Position { line: 494, column: 18, }, end: Position { line: 494, column: 22, }, }, }, ), ], to: BinaryOperation( BinaryOperation { left: List( List { elements: [ Identifier( Identifier { id: "el", span: Span { start: Position { line: 494, column: 27, }, end: Position { line: 494, column: 29, }, }, }, ), ], span: Span { start: Position { line: 494, column: 25, }, end: Position { line: 494, column: 31, }, }, }, ), operator: Concatenation, right: Identifier( Identifier { id: "left", span: Span { start: Position { line: 494, column: 35, }, end: Position { line: 494, column: 39, }, }, }, ), }, ), }, ), Inherit( BindingInherit { from: None, attributes: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 494, column: 49, }, end: Position { line: 494, column: 54, }, }, }, ), ], span: Span { start: Position { line: 494, column: 17, }, end: Position { line: 494, column: 55, }, }, }, ), ], span: Span { start: Position { line: 494, column: 16, }, end: Position { line: 494, column: 57, }, }, }, ), ], }, ), span: Span { start: Position { line: 491, column: 14, }, end: Position { line: 494, column: 57, }, }, }, ), span: Span { start: Position { line: 489, column: 9, }, end: Position { line: 494, column: 57, }, }, }, ), span: Span { start: Position { line: 488, column: 40, }, end: Position { line: 494, column: 57, }, }, }, ), span: Span { start: Position { line: 488, column: 19, }, end: Position { line: 494, column: 57, }, }, }, ), span: Span { start: Position { line: 488, column: 16, }, end: Position { line: 494, column: 57, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "pivot", span: Span { start: Position { line: 495, column: 7, }, end: Position { line: 495, column: 12, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "pivot'", span: Span { start: Position { line: 495, column: 15, }, end: Position { line: 495, column: 21, }, }, }, ), arguments: [ Integer( Integer { value: "1", span: Span { start: Position { line: 495, column: 22, }, end: Position { line: 495, column: 23, }, }, }, ), Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "left", span: Span { start: Position { line: 495, column: 26, }, end: Position { line: 495, column: 30, }, }, }, ), ], to: List( List { elements: [], span: Span { start: Position { line: 495, column: 33, }, end: Position { line: 495, column: 35, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 495, column: 37, }, end: Position { line: 495, column: 42, }, }, }, ), ], to: List( List { elements: [], span: Span { start: Position { line: 495, column: 45, }, end: Position { line: 495, column: 47, }, }, }, ), }, ), ], span: Span { start: Position { line: 495, column: 24, }, end: Position { line: 495, column: 50, }, }, }, ), ], }, ), }, ), ], target: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "len", span: Span { start: Position { line: 497, column: 10, }, end: Position { line: 497, column: 13, }, }, }, ), operator: LessThan, right: Integer( Integer { value: "2", span: Span { start: Position { line: 497, column: 16, }, end: Position { line: 497, column: 17, }, }, }, ), }, ), then: Identifier( Identifier { id: "list", span: Span { start: Position { line: 497, column: 23, }, end: Position { line: 497, column: 27, }, }, }, ), else_: BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "sort", span: Span { start: Position { line: 498, column: 13, }, end: Position { line: 498, column: 17, }, }, }, ), arguments: [ Identifier( Identifier { id: "strictLess", span: Span { start: Position { line: 498, column: 18, }, end: Position { line: 498, column: 28, }, }, }, ), PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pivot", span: Span { start: Position { line: 498, column: 29, }, end: Position { line: 498, column: 34, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "left", span: Span { start: Position { line: 498, column: 35, }, end: Position { line: 498, column: 39, }, }, }, ), ], default: None, }, ), ], }, ), operator: Concatenation, right: BinaryOperation( BinaryOperation { left: List( List { elements: [ Identifier( Identifier { id: "first", span: Span { start: Position { line: 498, column: 47, }, end: Position { line: 498, column: 52, }, }, }, ), ], span: Span { start: Position { line: 498, column: 45, }, end: Position { line: 498, column: 54, }, }, }, ), operator: Concatenation, right: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "sort", span: Span { start: Position { line: 498, column: 60, }, end: Position { line: 498, column: 64, }, }, }, ), arguments: [ Identifier( Identifier { id: "strictLess", span: Span { start: Position { line: 498, column: 65, }, end: Position { line: 498, column: 75, }, }, }, ), PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pivot", span: Span { start: Position { line: 498, column: 76, }, end: Position { line: 498, column: 81, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "right", span: Span { start: Position { line: 498, column: 82, }, end: Position { line: 498, column: 87, }, }, }, ), ], default: None, }, ), ], }, ), }, ), }, ), span: Span { start: Position { line: 497, column: 7, }, end: Position { line: 498, column: 88, }, }, }, ), span: Span { start: Position { line: 485, column: 5, }, end: Position { line: 498, column: 88, }, }, }, ), span: Span { start: Position { line: 484, column: 17, }, end: Position { line: 498, column: 88, }, }, }, ), span: Span { start: Position { line: 484, column: 5, }, end: Position { line: 498, column: 88, }, }, }, ), ), }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "compareLists", span: Span { start: Position { line: 512, column: 3, }, end: Position { line: 512, column: 15, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "cmp", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "a", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "b", }, ), body: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "a", span: Span { start: Position { line: 513, column: 8, }, end: Position { line: 513, column: 9, }, }, }, ), operator: EqualTo, right: List( List { elements: [], span: Span { start: Position { line: 513, column: 13, }, end: Position { line: 513, column: 15, }, }, }, ), }, ), then: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "b", span: Span { start: Position { line: 514, column: 13, }, end: Position { line: 514, column: 14, }, }, }, ), operator: EqualTo, right: List( List { elements: [], span: Span { start: Position { line: 514, column: 18, }, end: Position { line: 514, column: 20, }, }, }, ), }, ), then: Integer( Integer { value: "0", span: Span { start: Position { line: 515, column: 15, }, end: Position { line: 515, column: 16, }, }, }, ), else_: UnaryOperation( UnaryOperation { operator: Negate, operand: Integer( Integer { value: "1", span: Span { start: Position { line: 516, column: 16, }, end: Position { line: 516, column: 17, }, }, }, ), span: Span { start: Position { line: 516, column: 15, }, end: Position { line: 516, column: 17, }, }, }, ), span: Span { start: Position { line: 514, column: 10, }, end: Position { line: 516, column: 17, }, }, }, ), else_: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "b", span: Span { start: Position { line: 517, column: 13, }, end: Position { line: 517, column: 14, }, }, }, ), operator: EqualTo, right: List( List { elements: [], span: Span { start: Position { line: 517, column: 18, }, end: Position { line: 517, column: 20, }, }, }, ), }, ), then: Integer( Integer { value: "1", span: Span { start: Position { line: 518, column: 15, }, end: Position { line: 518, column: 16, }, }, }, ), else_: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "rel", span: Span { start: Position { line: 519, column: 19, }, end: Position { line: 519, column: 22, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "cmp", span: Span { start: Position { line: 519, column: 25, }, end: Position { line: 519, column: 28, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 519, column: 30, }, end: Position { line: 519, column: 34, }, }, }, ), arguments: [ Identifier( Identifier { id: "a", span: Span { start: Position { line: 519, column: 35, }, end: Position { line: 519, column: 36, }, }, }, ), ], }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 519, column: 39, }, end: Position { line: 519, column: 43, }, }, }, ), arguments: [ Identifier( Identifier { id: "b", span: Span { start: Position { line: 519, column: 44, }, end: Position { line: 519, column: 45, }, }, }, ), ], }, ), ], }, ), }, ), ], target: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "rel", span: Span { start: Position { line: 520, column: 18, }, end: Position { line: 520, column: 21, }, }, }, ), operator: EqualTo, right: Integer( Integer { value: "0", span: Span { start: Position { line: 520, column: 25, }, end: Position { line: 520, column: 26, }, }, }, ), }, ), then: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "compareLists", span: Span { start: Position { line: 521, column: 20, }, end: Position { line: 521, column: 32, }, }, }, ), arguments: [ Identifier( Identifier { id: "cmp", span: Span { start: Position { line: 521, column: 33, }, end: Position { line: 521, column: 36, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "tail", span: Span { start: Position { line: 521, column: 38, }, end: Position { line: 521, column: 42, }, }, }, ), arguments: [ Identifier( Identifier { id: "a", span: Span { start: Position { line: 521, column: 43, }, end: Position { line: 521, column: 44, }, }, }, ), ], }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "tail", span: Span { start: Position { line: 521, column: 47, }, end: Position { line: 521, column: 51, }, }, }, ), arguments: [ Identifier( Identifier { id: "b", span: Span { start: Position { line: 521, column: 52, }, end: Position { line: 521, column: 53, }, }, }, ), ], }, ), ], }, ), else_: Identifier( Identifier { id: "rel", span: Span { start: Position { line: 522, column: 20, }, end: Position { line: 522, column: 23, }, }, }, ), span: Span { start: Position { line: 520, column: 15, }, end: Position { line: 522, column: 23, }, }, }, ), span: Span { start: Position { line: 519, column: 15, }, end: Position { line: 522, column: 23, }, }, }, ), span: Span { start: Position { line: 517, column: 10, }, end: Position { line: 522, column: 23, }, }, }, ), span: Span { start: Position { line: 513, column: 5, }, end: Position { line: 522, column: 23, }, }, }, ), span: Span { start: Position { line: 512, column: 26, }, end: Position { line: 522, column: 23, }, }, }, ), span: Span { start: Position { line: 512, column: 23, }, end: Position { line: 522, column: 23, }, }, }, ), span: Span { start: Position { line: 512, column: 18, }, end: Position { line: 522, column: 23, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "naturalSort", span: Span { start: Position { line: 535, column: 3, }, end: Position { line: 535, column: 14, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "lst", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "vectorise", span: Span { start: Position { line: 537, column: 7, }, end: Position { line: 537, column: 16, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "s", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "map", span: Span { start: Position { line: 537, column: 22, }, end: Position { line: 537, column: 25, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "isList", span: Span { start: Position { line: 537, column: 33, }, end: Position { line: 537, column: 39, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 537, column: 40, }, end: Position { line: 537, column: 41, }, }, }, ), ], }, ), then: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "toInt", span: Span { start: Position { line: 537, column: 47, }, end: Position { line: 537, column: 52, }, }, }, ), arguments: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 537, column: 54, }, end: Position { line: 537, column: 58, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 537, column: 59, }, end: Position { line: 537, column: 60, }, }, }, ), ], }, ), ], }, ), else_: Identifier( Identifier { id: "x", span: Span { start: Position { line: 537, column: 67, }, end: Position { line: 537, column: 68, }, }, }, ), span: Span { start: Position { line: 537, column: 30, }, end: Position { line: 537, column: 68, }, }, }, ), span: Span { start: Position { line: 537, column: 27, }, end: Position { line: 537, column: 68, }, }, }, ), FunctionApplication( FunctionApplication { function: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 537, column: 71, }, end: Position { line: 537, column: 79, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "split", span: Span { start: Position { line: 537, column: 80, }, end: Position { line: 537, column: 85, }, }, }, ), ], default: None, }, ), arguments: [ String( String_ { parts: [ Raw( PartRaw { content: "(0|[1-9][0-9]*)", span: Span { start: Position { line: 537, column: 87, }, end: Position { line: 537, column: 102, }, }, }, ), ], span: Span { start: Position { line: 537, column: 86, }, end: Position { line: 537, column: 103, }, }, }, ), Identifier( Identifier { id: "s", span: Span { start: Position { line: 537, column: 104, }, end: Position { line: 537, column: 105, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 537, column: 19, }, end: Position { line: 537, column: 106, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "prepared", span: Span { start: Position { line: 538, column: 7, }, end: Position { line: 538, column: 15, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "map", span: Span { start: Position { line: 538, column: 18, }, end: Position { line: 538, column: 21, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: List( List { elements: [ FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "vectorise", span: Span { start: Position { line: 538, column: 29, }, end: Position { line: 538, column: 38, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 538, column: 39, }, end: Position { line: 538, column: 40, }, }, }, ), ], }, ), Identifier( Identifier { id: "x", span: Span { start: Position { line: 538, column: 42, }, end: Position { line: 538, column: 43, }, }, }, ), ], span: Span { start: Position { line: 538, column: 26, }, end: Position { line: 538, column: 45, }, }, }, ), span: Span { start: Position { line: 538, column: 23, }, end: Position { line: 538, column: 45, }, }, }, ), Identifier( Identifier { id: "lst", span: Span { start: Position { line: 538, column: 47, }, end: Position { line: 538, column: 50, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "less", span: Span { start: Position { line: 539, column: 7, }, end: Position { line: 539, column: 11, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "a", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "b", }, ), body: BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "compareLists", span: Span { start: Position { line: 539, column: 21, }, end: Position { line: 539, column: 33, }, }, }, ), arguments: [ Identifier( Identifier { id: "compare", span: Span { start: Position { line: 539, column: 34, }, end: Position { line: 539, column: 41, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 539, column: 43, }, end: Position { line: 539, column: 47, }, }, }, ), arguments: [ Identifier( Identifier { id: "a", span: Span { start: Position { line: 539, column: 48, }, end: Position { line: 539, column: 49, }, }, }, ), ], }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "head", span: Span { start: Position { line: 539, column: 52, }, end: Position { line: 539, column: 56, }, }, }, ), arguments: [ Identifier( Identifier { id: "b", span: Span { start: Position { line: 539, column: 57, }, end: Position { line: 539, column: 58, }, }, }, ), ], }, ), ], }, ), operator: LessThan, right: Integer( Integer { value: "0", span: Span { start: Position { line: 539, column: 63, }, end: Position { line: 539, column: 64, }, }, }, ), }, ), span: Span { start: Position { line: 539, column: 17, }, end: Position { line: 539, column: 64, }, }, }, ), span: Span { start: Position { line: 539, column: 14, }, end: Position { line: 539, column: 64, }, }, }, ), }, ), ], target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "map", span: Span { start: Position { line: 541, column: 7, }, end: Position { line: 541, column: 10, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 541, column: 15, }, end: Position { line: 541, column: 21, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 541, column: 22, }, end: Position { line: 541, column: 23, }, }, }, ), Integer( Integer { value: "1", span: Span { start: Position { line: 541, column: 24, }, end: Position { line: 541, column: 25, }, }, }, ), ], }, ), span: Span { start: Position { line: 541, column: 12, }, end: Position { line: 541, column: 25, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "sort", span: Span { start: Position { line: 541, column: 28, }, end: Position { line: 541, column: 32, }, }, }, ), arguments: [ Identifier( Identifier { id: "less", span: Span { start: Position { line: 541, column: 33, }, end: Position { line: 541, column: 37, }, }, }, ), Identifier( Identifier { id: "prepared", span: Span { start: Position { line: 541, column: 38, }, end: Position { line: 541, column: 46, }, }, }, ), ], }, ), ], }, ), span: Span { start: Position { line: 536, column: 5, }, end: Position { line: 541, column: 47, }, }, }, ), span: Span { start: Position { line: 535, column: 17, }, end: Position { line: 541, column: 47, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "take", span: Span { start: Position { line: 553, column: 3, }, end: Position { line: 553, column: 7, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "count", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "sublist", span: Span { start: Position { line: 555, column: 12, }, end: Position { line: 555, column: 19, }, }, }, ), arguments: [ Integer( Integer { value: "0", span: Span { start: Position { line: 555, column: 20, }, end: Position { line: 555, column: 21, }, }, }, ), Identifier( Identifier { id: "count", span: Span { start: Position { line: 555, column: 22, }, end: Position { line: 555, column: 27, }, }, }, ), ], }, ), span: Span { start: Position { line: 555, column: 5, }, end: Position { line: 555, column: 27, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "drop", span: Span { start: Position { line: 567, column: 3, }, end: Position { line: 567, column: 7, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "count", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "sublist", span: Span { start: Position { line: 571, column: 11, }, end: Position { line: 571, column: 18, }, }, }, ), arguments: [ Identifier( Identifier { id: "count", span: Span { start: Position { line: 571, column: 19, }, end: Position { line: 571, column: 24, }, }, }, ), FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 571, column: 26, }, end: Position { line: 571, column: 32, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 571, column: 33, }, end: Position { line: 571, column: 37, }, }, }, ), ], }, ), Identifier( Identifier { id: "list", span: Span { start: Position { line: 571, column: 39, }, end: Position { line: 571, column: 43, }, }, }, ), ], }, ), span: Span { start: Position { line: 571, column: 5, }, end: Position { line: 571, column: 43, }, }, }, ), span: Span { start: Position { line: 569, column: 5, }, end: Position { line: 571, column: 43, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "sublist", span: Span { start: Position { line: 584, column: 3, }, end: Position { line: 584, column: 10, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "start", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "count", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "len", span: Span { start: Position { line: 591, column: 9, }, end: Position { line: 591, column: 12, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 591, column: 15, }, end: Position { line: 591, column: 21, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 591, column: 22, }, end: Position { line: 591, column: 26, }, }, }, ), ], }, ), }, ), ], target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "genList", span: Span { start: Position { line: 592, column: 5, }, end: Position { line: 592, column: 12, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "n", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 593, column: 11, }, end: Position { line: 593, column: 17, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 593, column: 18, }, end: Position { line: 593, column: 22, }, }, }, ), BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "n", span: Span { start: Position { line: 593, column: 24, }, end: Position { line: 593, column: 25, }, }, }, ), operator: Addition, right: Identifier( Identifier { id: "start", span: Span { start: Position { line: 593, column: 28, }, end: Position { line: 593, column: 33, }, }, }, ), }, ), ], }, ), span: Span { start: Position { line: 593, column: 8, }, end: Position { line: 593, column: 34, }, }, }, ), IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "start", span: Span { start: Position { line: 594, column: 11, }, end: Position { line: 594, column: 16, }, }, }, ), operator: GreaterThanOrEqualTo, right: Identifier( Identifier { id: "len", span: Span { start: Position { line: 594, column: 20, }, end: Position { line: 594, column: 23, }, }, }, ), }, ), then: Integer( Integer { value: "0", span: Span { start: Position { line: 594, column: 29, }, end: Position { line: 594, column: 30, }, }, }, ), else_: IfThenElse( IfThenElse { predicate: BinaryOperation( BinaryOperation { left: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "start", span: Span { start: Position { line: 595, column: 16, }, end: Position { line: 595, column: 21, }, }, }, ), operator: Addition, right: Identifier( Identifier { id: "count", span: Span { start: Position { line: 595, column: 24, }, end: Position { line: 595, column: 29, }, }, }, ), }, ), operator: GreaterThan, right: Identifier( Identifier { id: "len", span: Span { start: Position { line: 595, column: 32, }, end: Position { line: 595, column: 35, }, }, }, ), }, ), then: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "len", span: Span { start: Position { line: 595, column: 41, }, end: Position { line: 595, column: 44, }, }, }, ), operator: Subtraction, right: Identifier( Identifier { id: "start", span: Span { start: Position { line: 595, column: 47, }, end: Position { line: 595, column: 52, }, }, }, ), }, ), else_: Identifier( Identifier { id: "count", span: Span { start: Position { line: 596, column: 13, }, end: Position { line: 596, column: 18, }, }, }, ), span: Span { start: Position { line: 595, column: 13, }, end: Position { line: 596, column: 18, }, }, }, ), span: Span { start: Position { line: 594, column: 8, }, end: Position { line: 596, column: 18, }, }, }, ), ], }, ), span: Span { start: Position { line: 591, column: 5, }, end: Position { line: 596, column: 19, }, }, }, ), span: Span { start: Position { line: 590, column: 5, }, end: Position { line: 596, column: 19, }, }, }, ), span: Span { start: Position { line: 588, column: 5, }, end: Position { line: 596, column: 19, }, }, }, ), span: Span { start: Position { line: 586, column: 5, }, end: Position { line: 596, column: 19, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "last", span: Span { start: Position { line: 608, column: 3, }, end: Position { line: 608, column: 7, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: Assert( Assert { expression: FunctionApplication( FunctionApplication { function: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "lib", span: Span { start: Position { line: 609, column: 12, }, end: Position { line: 609, column: 15, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "assertMsg", span: Span { start: Position { line: 609, column: 16, }, end: Position { line: 609, column: 25, }, }, }, ), ], default: None, }, ), arguments: [ BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "list", span: Span { start: Position { line: 609, column: 27, }, end: Position { line: 609, column: 31, }, }, }, ), operator: NotEqualTo, right: List( List { elements: [], span: Span { start: Position { line: 609, column: 35, }, end: Position { line: 609, column: 37, }, }, }, ), }, ), String( String_ { parts: [ Raw( PartRaw { content: "lists.last: list must not be empty!", span: Span { start: Position { line: 609, column: 40, }, end: Position { line: 609, column: 75, }, }, }, ), ], span: Span { start: Position { line: 609, column: 39, }, end: Position { line: 609, column: 76, }, }, }, ), ], }, ), target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elemAt", span: Span { start: Position { line: 610, column: 5, }, end: Position { line: 610, column: 11, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 610, column: 12, }, end: Position { line: 610, column: 16, }, }, }, ), BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 610, column: 18, }, end: Position { line: 610, column: 24, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 610, column: 25, }, end: Position { line: 610, column: 29, }, }, }, ), ], }, ), operator: Subtraction, right: Integer( Integer { value: "1", span: Span { start: Position { line: 610, column: 32, }, end: Position { line: 610, column: 33, }, }, }, ), }, ), ], }, ), span: Span { start: Position { line: 609, column: 5, }, end: Position { line: 610, column: 34, }, }, }, ), span: Span { start: Position { line: 608, column: 10, }, end: Position { line: 610, column: 34, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "init", span: Span { start: Position { line: 622, column: 3, }, end: Position { line: 622, column: 7, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "list", }, ), body: Assert( Assert { expression: FunctionApplication( FunctionApplication { function: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "lib", span: Span { start: Position { line: 623, column: 12, }, end: Position { line: 623, column: 15, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "assertMsg", span: Span { start: Position { line: 623, column: 16, }, end: Position { line: 623, column: 25, }, }, }, ), ], default: None, }, ), arguments: [ BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "list", span: Span { start: Position { line: 623, column: 27, }, end: Position { line: 623, column: 31, }, }, }, ), operator: NotEqualTo, right: List( List { elements: [], span: Span { start: Position { line: 623, column: 35, }, end: Position { line: 623, column: 37, }, }, }, ), }, ), String( String_ { parts: [ Raw( PartRaw { content: "lists.init: list must not be empty!", span: Span { start: Position { line: 623, column: 40, }, end: Position { line: 623, column: 75, }, }, }, ), ], span: Span { start: Position { line: 623, column: 39, }, end: Position { line: 623, column: 76, }, }, }, ), ], }, ), target: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "take", span: Span { start: Position { line: 624, column: 5, }, end: Position { line: 624, column: 9, }, }, }, ), arguments: [ BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 624, column: 11, }, end: Position { line: 624, column: 17, }, }, }, ), arguments: [ Identifier( Identifier { id: "list", span: Span { start: Position { line: 624, column: 18, }, end: Position { line: 624, column: 22, }, }, }, ), ], }, ), operator: Subtraction, right: Integer( Integer { value: "1", span: Span { start: Position { line: 624, column: 25, }, end: Position { line: 624, column: 26, }, }, }, ), }, ), Identifier( Identifier { id: "list", span: Span { start: Position { line: 624, column: 28, }, end: Position { line: 624, column: 32, }, }, }, ), ], }, ), span: Span { start: Position { line: 623, column: 5, }, end: Position { line: 624, column: 32, }, }, }, ), span: Span { start: Position { line: 622, column: 10, }, end: Position { line: 624, column: 32, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "crossLists", span: Span { start: Position { line: 633, column: 3, }, end: Position { line: 633, column: 13, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "builtins", span: Span { start: Position { line: 633, column: 16, }, end: Position { line: 633, column: 24, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "trace", span: Span { start: Position { line: 633, column: 25, }, end: Position { line: 633, column: 30, }, }, }, ), ], default: None, }, ), arguments: [ String( String_ { parts: [ Raw( PartRaw { content: "lib.crossLists is deprecated, use lib.cartesianProductOfSets instead", span: Span { start: Position { line: 634, column: 6, }, end: Position { line: 634, column: 74, }, }, }, ), ], span: Span { start: Position { line: 634, column: 5, }, end: Position { line: 634, column: 75, }, }, }, ), Function( Function { head: Simple( FunctionHeadSimple { identifier: "f", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldl", span: Span { start: Position { line: 635, column: 9, }, end: Position { line: 635, column: 14, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "fs", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "args", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "concatMap", span: Span { start: Position { line: 635, column: 26, }, end: Position { line: 635, column: 35, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "f", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "map", span: Span { start: Position { line: 635, column: 40, }, end: Position { line: 635, column: 43, }, }, }, ), arguments: [ Identifier( Identifier { id: "f", span: Span { start: Position { line: 635, column: 44, }, end: Position { line: 635, column: 45, }, }, }, ), Identifier( Identifier { id: "args", span: Span { start: Position { line: 635, column: 46, }, end: Position { line: 635, column: 50, }, }, }, ), ], }, ), span: Span { start: Position { line: 635, column: 37, }, end: Position { line: 635, column: 50, }, }, }, ), Identifier( Identifier { id: "fs", span: Span { start: Position { line: 635, column: 52, }, end: Position { line: 635, column: 54, }, }, }, ), ], }, ), span: Span { start: Position { line: 635, column: 20, }, end: Position { line: 635, column: 54, }, }, }, ), span: Span { start: Position { line: 635, column: 16, }, end: Position { line: 635, column: 54, }, }, }, ), List( List { elements: [ Identifier( Identifier { id: "f", span: Span { start: Position { line: 635, column: 57, }, end: Position { line: 635, column: 58, }, }, }, ), ], span: Span { start: Position { line: 635, column: 56, }, end: Position { line: 635, column: 59, }, }, }, ), ], }, ), span: Span { start: Position { line: 635, column: 6, }, end: Position { line: 635, column: 59, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "unique", span: Span { start: Position { line: 646, column: 3, }, end: Position { line: 646, column: 9, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "foldl'", span: Span { start: Position { line: 646, column: 12, }, end: Position { line: 646, column: 18, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "acc", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "e", }, ), body: IfThenElse( IfThenElse { predicate: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elem", span: Span { start: Position { line: 646, column: 31, }, end: Position { line: 646, column: 35, }, }, }, ), arguments: [ Identifier( Identifier { id: "e", span: Span { start: Position { line: 646, column: 36, }, end: Position { line: 646, column: 37, }, }, }, ), Identifier( Identifier { id: "acc", span: Span { start: Position { line: 646, column: 38, }, end: Position { line: 646, column: 41, }, }, }, ), ], }, ), then: Identifier( Identifier { id: "acc", span: Span { start: Position { line: 646, column: 47, }, end: Position { line: 646, column: 50, }, }, }, ), else_: BinaryOperation( BinaryOperation { left: Identifier( Identifier { id: "acc", span: Span { start: Position { line: 646, column: 56, }, end: Position { line: 646, column: 59, }, }, }, ), operator: Concatenation, right: List( List { elements: [ Identifier( Identifier { id: "e", span: Span { start: Position { line: 646, column: 65, }, end: Position { line: 646, column: 66, }, }, }, ), ], span: Span { start: Position { line: 646, column: 63, }, end: Position { line: 646, column: 68, }, }, }, ), }, ), span: Span { start: Position { line: 646, column: 28, }, end: Position { line: 646, column: 68, }, }, }, ), span: Span { start: Position { line: 646, column: 25, }, end: Position { line: 646, column: 68, }, }, }, ), span: Span { start: Position { line: 646, column: 20, }, end: Position { line: 646, column: 68, }, }, }, ), List( List { elements: [], span: Span { start: Position { line: 646, column: 70, }, end: Position { line: 646, column: 72, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "intersectLists", span: Span { start: Position { line: 654, column: 3, }, end: Position { line: 654, column: 17, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "e", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "filter", span: Span { start: Position { line: 654, column: 23, }, end: Position { line: 654, column: 29, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elem", span: Span { start: Position { line: 654, column: 34, }, end: Position { line: 654, column: 38, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 654, column: 39, }, end: Position { line: 654, column: 40, }, }, }, ), Identifier( Identifier { id: "e", span: Span { start: Position { line: 654, column: 41, }, end: Position { line: 654, column: 42, }, }, }, ), ], }, ), span: Span { start: Position { line: 654, column: 31, }, end: Position { line: 654, column: 42, }, }, }, ), ], }, ), span: Span { start: Position { line: 654, column: 20, }, end: Position { line: 654, column: 43, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "subtractLists", span: Span { start: Position { line: 662, column: 3, }, end: Position { line: 662, column: 16, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "e", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "filter", span: Span { start: Position { line: 662, column: 22, }, end: Position { line: 662, column: 28, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: UnaryOperation( UnaryOperation { operator: Not, operand: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elem", span: Span { start: Position { line: 662, column: 35, }, end: Position { line: 662, column: 39, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 662, column: 40, }, end: Position { line: 662, column: 41, }, }, }, ), Identifier( Identifier { id: "e", span: Span { start: Position { line: 662, column: 42, }, end: Position { line: 662, column: 43, }, }, }, ), ], }, ), span: Span { start: Position { line: 662, column: 33, }, end: Position { line: 662, column: 44, }, }, }, ), span: Span { start: Position { line: 662, column: 30, }, end: Position { line: 662, column: 44, }, }, }, ), ], }, ), span: Span { start: Position { line: 662, column: 19, }, end: Position { line: 662, column: 45, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "mutuallyExclusive", span: Span { start: Position { line: 667, column: 3, }, end: Position { line: 667, column: 20, }, }, }, ), ], to: Function( Function { head: Simple( FunctionHeadSimple { identifier: "a", }, ), body: Function( Function { head: Simple( FunctionHeadSimple { identifier: "b", }, ), body: BinaryOperation( BinaryOperation { left: BinaryOperation( BinaryOperation { left: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "length", span: Span { start: Position { line: 667, column: 29, }, end: Position { line: 667, column: 35, }, }, }, ), arguments: [ Identifier( Identifier { id: "a", span: Span { start: Position { line: 667, column: 36, }, end: Position { line: 667, column: 37, }, }, }, ), ], }, ), operator: EqualTo, right: Integer( Integer { value: "0", span: Span { start: Position { line: 667, column: 41, }, end: Position { line: 667, column: 42, }, }, }, ), }, ), operator: LogicalOr, right: UnaryOperation( UnaryOperation { operator: Not, operand: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "any", span: Span { start: Position { line: 667, column: 48, }, end: Position { line: 667, column: 51, }, }, }, ), arguments: [ Function( Function { head: Simple( FunctionHeadSimple { identifier: "x", }, ), body: FunctionApplication( FunctionApplication { function: Identifier( Identifier { id: "elem", span: Span { start: Position { line: 667, column: 56, }, end: Position { line: 667, column: 60, }, }, }, ), arguments: [ Identifier( Identifier { id: "x", span: Span { start: Position { line: 667, column: 61, }, end: Position { line: 667, column: 62, }, }, }, ), Identifier( Identifier { id: "a", span: Span { start: Position { line: 667, column: 63, }, end: Position { line: 667, column: 64, }, }, }, ), ], }, ), span: Span { start: Position { line: 667, column: 53, }, end: Position { line: 667, column: 64, }, }, }, ), Identifier( Identifier { id: "b", span: Span { start: Position { line: 667, column: 66, }, end: Position { line: 667, column: 67, }, }, }, ), ], }, ), span: Span { start: Position { line: 667, column: 46, }, end: Position { line: 667, column: 68, }, }, }, ), }, ), span: Span { start: Position { line: 667, column: 26, }, end: Position { line: 667, column: 68, }, }, }, ), span: Span { start: Position { line: 667, column: 23, }, end: Position { line: 667, column: 68, }, }, }, ), }, ), ], span: Span { start: Position { line: 9, column: 1, }, end: Position { line: 669, column: 2, }, }, }, ), span: Span { start: Position { line: 4, column: 1, }, end: Position { line: 669, column: 2, }, }, }, ), span: Span { start: Position { line: 3, column: 1, }, end: Position { line: 669, column: 2, }, }, }, )