diff options
Diffstat (limited to 'stdlib/source/library/lux/target/jvm/type/signature.lux')
-rw-r--r-- | stdlib/source/library/lux/target/jvm/type/signature.lux | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/stdlib/source/library/lux/target/jvm/type/signature.lux b/stdlib/source/library/lux/target/jvm/type/signature.lux index 610706176..288b0a75e 100644 --- a/stdlib/source/library/lux/target/jvm/type/signature.lux +++ b/stdlib/source/library/lux/target/jvm/type/signature.lux @@ -23,12 +23,12 @@ (primitive .public (Signature category) Text - (def: .public signature + (def .public signature (-> (Signature Any) Text) (|>> representation)) (with_template [<category> <name> <descriptor>] - [(def: .public <name> + [(def .public <name> (Signature <category>) (abstraction (//descriptor.descriptor <descriptor>)))] @@ -43,18 +43,18 @@ [Primitive char //descriptor.char] ) - (def: .public array + (def .public array (-> (Signature Value) (Signature Array)) (|>> representation (format //descriptor.array_prefix) abstraction)) - (def: .public wildcard + (def .public wildcard (Signature Parameter) (abstraction "*")) (with_template [<char> <name>] - [(def: .public <name> <char>)] + [(def .public <name> <char>)] ["T" var_prefix] ["-" lower_prefix] @@ -70,7 +70,7 @@ ) (with_template [<name> <prefix>] - [(def: .public <name> + [(def .public <name> (-> (Signature Parameter) (Signature Parameter)) (|>> representation (format <prefix>) abstraction))] @@ -78,18 +78,18 @@ [upper ..upper_prefix] ) - (def: .public var + (def .public var (-> Text (Signature Var)) (|>> (text.enclosed [..var_prefix //descriptor.class_suffix]) abstraction)) - (def: .public var_name + (def .public var_name (-> (Signature Var) Text) (|>> representation (text.replaced ..var_prefix "") (text.replaced //descriptor.class_suffix ""))) - (def: .public (class name parameters) + (def .public (class name parameters) (-> External (List (Signature Parameter)) (Signature Class)) (abstraction (format //descriptor.class_prefix @@ -106,28 +106,28 @@ ..parameters_end)) //descriptor.class_suffix))) - (def: .public (declaration name variables) + (def .public (declaration name variables) (-> External (List (Signature Var)) (Signature Declaration)) (transmutation (..class name variables))) - (def: class_bound + (def class_bound (|> (..class "java.lang.Object" (list)) ..signature (format ..format_type_parameter_infix))) - (def: var_declaration/1 + (def var_declaration/1 (-> (Signature Var) Text) (|>> ..var_name (text.suffix ..class_bound))) - (def: var_declaration/+ + (def var_declaration/+ (-> (List (Signature Var)) Text) (|>> (list#each ..var_declaration/1) text.together (text.enclosed [..parameters_start ..parameters_end]))) - (def: var_declaration/* + (def var_declaration/* (-> (List (Signature Var)) Text) (|>> (pipe.case {.#End} @@ -136,7 +136,7 @@ it (..var_declaration/+ it)))) - (def: .public (inheritance variables super interfaces) + (def .public (inheritance variables super interfaces) (-> (List (Signature Var)) (Signature Class) (List (Signature Class)) (Signature Inheritance)) (abstraction (format (var_declaration/* variables) @@ -145,11 +145,11 @@ (list#each ..signature) text.together)))) - (def: .public as_class + (def .public as_class (-> (Signature Declaration) (Signature Class)) (|>> transmutation)) - (def: .public (method [type_variables inputs output exceptions]) + (def .public (method [type_variables inputs output exceptions]) (-> [(List (Signature Var)) (List (Signature Value)) (Signature Return) @@ -167,16 +167,16 @@ (list#each (|>> representation (format ..exception_prefix))) text.together)))) - (def: .public equivalence + (def .public equivalence (All (_ category) (Equivalence (Signature category))) (implementation - (def: (= parameter subject) + (def (= parameter subject) (text#= (representation parameter) (representation subject))))) - (def: .public hash + (def .public hash (All (_ category) (Hash (Signature category))) (implementation - (def: equivalence ..equivalence) - (def: hash (|>> representation text#hash)))) + (def equivalence ..equivalence) + (def hash (|>> representation text#hash)))) ) |