From e76add6e6f904677f5c09bb2a66dce283f1b848a Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Wed, 1 Sep 2021 01:49:59 -0400 Subject: De-taggification | part 1 --- stdlib/source/documentation/lux/ffi.jvm.lux | 32 ++++---- stdlib/source/documentation/lux/ffi.old.lux | 32 ++++---- stdlib/source/documentation/lux/ffi.rb.lux | 2 +- stdlib/source/documentation/lux/macro.lux | 2 +- .../source/library/lux/data/text/encoding/utf8.lux | 8 +- stdlib/source/library/lux/ffi.js.lux | 2 +- stdlib/source/library/lux/ffi.jvm.lux | 46 ++++------- stdlib/source/library/lux/ffi.lua.lux | 2 +- stdlib/source/library/lux/ffi.old.lux | 46 ++++------- stdlib/source/library/lux/ffi.php.lux | 2 +- stdlib/source/library/lux/ffi.py.lux | 2 +- stdlib/source/library/lux/ffi.rb.lux | 2 +- stdlib/source/library/lux/ffi.scm.lux | 2 +- stdlib/source/library/lux/macro.lux | 2 +- stdlib/source/library/lux/target/jvm/loader.lux | 2 +- stdlib/source/library/lux/world/file.lux | 10 +-- stdlib/source/library/lux/world/program.lux | 18 ++-- stdlib/source/test/lux/ffi.jvm.lux | 96 +++++++++++----------- stdlib/source/test/lux/ffi.old.lux | 34 ++++---- stdlib/source/test/lux/macro.lux | 2 +- 20 files changed, 162 insertions(+), 182 deletions(-) (limited to 'stdlib') diff --git a/stdlib/source/documentation/lux/ffi.jvm.lux b/stdlib/source/documentation/lux/ffi.jvm.lux index c6d2a97ae..029999d03 100644 --- a/stdlib/source/documentation/lux/ffi.jvm.lux +++ b/stdlib/source/documentation/lux/ffi.jvm.lux @@ -83,22 +83,22 @@ (documentation: /.class: "Allows defining JVM classes in Lux code." - [(class: #final (TestClass A) [Runnable] + [(class: "final" (TestClass A) [Runnable] ... Fields - (#private foo boolean) - (#private bar A) - (#private baz java/lang/Object) + ("private" foo boolean) + ("private" bar A) + ("private" baz java/lang/Object) ... Methods - (#public [] (new [value A]) [] - (exec - (:= ::foo #1) - (:= ::bar value) - (:= ::baz "") - [])) - (#public (virtual) java/lang/Object - "") - (#public "static" (static) java/lang/Object - "") + ("public" [] (new [value A]) [] + (exec + (:= ::foo #1) + (:= ::bar value) + (:= ::baz "") + [])) + ("public" (virtual) java/lang/Object + "") + ("public" "static" (static) java/lang/Object + "") (Runnable [] (run) void []) ) @@ -115,7 +115,7 @@ (documentation: /.interface: "Allows defining JVM interfaces." [(interface: TestInterface - ([] foo [boolean String] void #throws [Exception]))]) + ([] foo [boolean String] void "throws" [Exception]))]) (documentation: /.object "Allows defining anonymous classes." @@ -194,7 +194,7 @@ ["#::." (new [[byte]]) ("static" valueOf [char] java/lang/String) - ("static" valueOf #as int_valueOf [int] java/lang/String)]) + ("static" valueOf "as" int_valueOf [int] java/lang/String)]) (import: (java/util/List e) ["#::." diff --git a/stdlib/source/documentation/lux/ffi.old.lux b/stdlib/source/documentation/lux/ffi.old.lux index 86e9a23b6..80d981b89 100644 --- a/stdlib/source/documentation/lux/ffi.old.lux +++ b/stdlib/source/documentation/lux/ffi.old.lux @@ -50,22 +50,22 @@ (documentation: /.class: "Allows defining JVM classes in Lux code." - [(class: #final (TestClass A) [Runnable] + [(class: "final" (TestClass A) [Runnable] ... Fields - (#private foo boolean) - (#private bar A) - (#private baz java/lang/Object) + ("private" foo boolean) + ("private" bar A) + ("private" baz java/lang/Object) ... Methods - (#public [] (new [value A]) [] - (exec - (:= ::foo #1) - (:= ::bar value) - (:= ::baz "") - [])) - (#public (virtual) java/lang/Object - "") - (#public "static" (static) java/lang/Object - "") + ("public" [] (new [value A]) [] + (exec + (:= ::foo #1) + (:= ::bar value) + (:= ::baz "") + [])) + ("public" (virtual) java/lang/Object + "") + ("public" "static" (static) java/lang/Object + "") (Runnable [] (run) void [])) "The tuple corresponds to parent interfaces." @@ -80,7 +80,7 @@ (documentation: /.interface: "Allows defining JVM interfaces." [(interface: TestInterface - ([] foo [boolean String] void #throws [Exception]))]) + ([] foo [boolean String] void "throws" [Exception]))]) (documentation: /.object "Allows defining anonymous classes." @@ -158,7 +158,7 @@ ["#::." (new [[byte]]) ("static" valueOf [char] java/lang/String) - ("static" valueOf #as int_valueOf [int] java/lang/String)]) + ("static" valueOf "as" int_valueOf [int] java/lang/String)]) (import: (java/util/List e) ["#::." diff --git a/stdlib/source/documentation/lux/ffi.rb.lux b/stdlib/source/documentation/lux/ffi.rb.lux index a257a7b26..5e6f96164 100644 --- a/stdlib/source/documentation/lux/ffi.rb.lux +++ b/stdlib/source/documentation/lux/ffi.rb.lux @@ -17,7 +17,7 @@ (executable? [] Bit) (size Int)]) - (import: File #as RubyFile + (import: File "as" RubyFile ["#::." ("static" SEPARATOR ..String) ("static" open [Path ..String] "io" "try" RubyFile) diff --git a/stdlib/source/documentation/lux/macro.lux b/stdlib/source/documentation/lux/macro.lux index f222d778c..a5125ff99 100644 --- a/stdlib/source/documentation/lux/macro.lux +++ b/stdlib/source/documentation/lux/macro.lux @@ -57,7 +57,7 @@ (format "Performs a macro-expansion and logs the resulting code." \n "You can either use the resulting code, or omit them." \n "By omitting them, this macro produces nothing (just like the lux.comment macro).") - [( #omit + [( "omit" (def: (foo bar baz) (-> Int Int Int) (int.+ bar baz)))])] diff --git a/stdlib/source/library/lux/data/text/encoding/utf8.lux b/stdlib/source/library/lux/data/text/encoding/utf8.lux index dd0881732..b8c821afd 100644 --- a/stdlib/source/library/lux/data/text/encoding/utf8.lux +++ b/stdlib/source/library/lux/data/text/encoding/utf8.lux @@ -24,8 +24,8 @@ ... On Node (ffi.import: Buffer ["#::." - ("static" from #as from|encoded [ffi.String ffi.String] Buffer) - ("static" from #as from|decoded [Uint8Array] Buffer) + ("static" from "as" from|encoded [ffi.String ffi.String] Buffer) + ("static" from "as" from|decoded [Uint8Array] Buffer) (toString [ffi.String] ffi.String)]) ... On the browser @@ -40,13 +40,13 @@ (decode [Uint8Array] ffi.String)])) @.ruby - (as_is (ffi.import: String #as RubyString + (as_is (ffi.import: String "as" RubyString ["#::." (encode [Text] RubyString) (force_encoding [Text] Text) (bytes [] Binary)]) - (ffi.import: Array #as RubyArray + (ffi.import: Array "as" RubyArray ["#::." (pack [Text] RubyString)])) diff --git a/stdlib/source/library/lux/ffi.js.lux b/stdlib/source/library/lux/ffi.js.lux index 6a130d4a1..466807a53 100644 --- a/stdlib/source/library/lux/ffi.js.lux +++ b/stdlib/source/library/lux/ffi.js.lux @@ -105,7 +105,7 @@ (Parser Common_Method) ($_ <>.and .local_identifier - (<>.maybe (<>.after (.this! (' #as)) .local_identifier)) + (<>.maybe (<>.after (.this! (' "as")) .local_identifier)) (.tuple (<>.some ..nullable)) (<>.parses? (.this! (' "io"))) (<>.parses? (.this! (' "try"))) diff --git a/stdlib/source/library/lux/ffi.jvm.lux b/stdlib/source/library/lux/ffi.jvm.lux index 412f5c0d6..da46af60c 100644 --- a/stdlib/source/library/lux/ffi.jvm.lux +++ b/stdlib/source/library/lux/ffi.jvm.lux @@ -537,17 +537,17 @@ (Parser Privacy) (let [(^open ".") <>.monad] ($_ <>.or - (.this! (' #public)) - (.this! (' #private)) - (.this! (' #protected)) + (.this! (' "public")) + (.this! (' "private")) + (.this! (' "protected")) (in [])))) (def: inheritance_modifier^ (Parser Inheritance) (let [(^open ".") <>.monad] ($_ <>.or - (.this! (' #final)) - (.this! (' #abstract)) + (.this! (' "final")) + (.this! (' "abstract")) (in [])))) (exception: .public (class_names_cannot_contain_periods {name Text}) @@ -719,14 +719,14 @@ (Parser (List Annotation)) (<| (<>.else (list)) (do <>.monad - [_ (.this! (' #ann))] + [_ (.this! (' "ann"))] (.tuple (<>.some ..annotation^))))) (def: (throws_decl^ type_vars) (-> (List (Type Var)) (Parser (List (Type Class)))) (<| (<>.else (list)) (do <>.monad - [_ (.this! (' #throws))] + [_ (.this! (' "throws"))] (.tuple (<>.some (..class^ type_vars)))))) (def: (method_decl^ type_vars) @@ -747,14 +747,14 @@ (def: state_modifier^ (Parser State) ($_ <>.or - (.this! (' #volatile)) - (.this! (' #final)) + (.this! (' "volatile")) + (.this! (' "final")) (\ <>.monad in []))) (def: (field_decl^ type_vars) (-> (List (Type Var)) (Parser [Member_Declaration FieldDecl])) (<>.either (.form (do <>.monad - [_ (.this! (' #const)) + [_ (.this! (' "const")) name .local_identifier anns ..annotations^ type (..type^ type_vars) @@ -789,7 +789,7 @@ (-> (List (Type Var)) (Parser [Member_Declaration Method_Definition])) (.form (do <>.monad [pm privacy_modifier^ - strict_fp? (<>.parses? (.this! (' #strict))) + strict_fp? (<>.parses? (.this! (' "strict"))) method_vars (<>.else (list) ..vars^) .let [total_vars (list\composite class_vars method_vars)] [_ self_name arguments] (.form ($_ <>.and @@ -809,8 +809,8 @@ (-> (List (Type Var)) (Parser [Member_Declaration Method_Definition])) (.form (do <>.monad [pm privacy_modifier^ - strict_fp? (<>.parses? (.this! (' #strict))) - final? (<>.parses? (.this! (' #final))) + strict_fp? (<>.parses? (.this! (' "strict"))) + final? (<>.parses? (.this! (' "final"))) method_vars (<>.else (list) ..vars^) .let [total_vars (list\composite class_vars method_vars)] [name self_name arguments] (.form ($_ <>.and @@ -829,7 +829,7 @@ (def: overriden_method_def^ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad - [strict_fp? (<>.parses? (.this! (' #strict))) + [strict_fp? (<>.parses? (.this! (' "strict"))) owner_class ..declaration^ method_vars (<>.else (list) ..vars^) .let [total_vars (list\composite (product.right (parser.declaration owner_class)) @@ -851,7 +851,7 @@ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad [pm privacy_modifier^ - strict_fp? (<>.parses? (.this! (' #strict))) + strict_fp? (<>.parses? (.this! (' "strict"))) _ (.this! (' "static")) method_vars (<>.else (list) ..vars^) .let [total_vars method_vars] @@ -870,7 +870,7 @@ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad [pm privacy_modifier^ - _ (.this! (' #abstract)) + _ (.this! (' "abstract")) method_vars (<>.else (list) ..vars^) .let [total_vars method_vars] [name arguments] (.form (<>.and .local_identifier @@ -887,7 +887,7 @@ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad [pm privacy_modifier^ - _ (.this! (' #native)) + _ (.this! (' "native")) method_vars (<>.else (list) ..vars^) .let [total_vars method_vars] [name arguments] (.form (<>.and .local_identifier @@ -914,20 +914,10 @@ (Parser Partial_Call) (.form (<>.and .identifier (<>.some .any)))) -(def: class_kind^ - (Parser Class_Kind) - (<>.either (do <>.monad - [_ (.this! (' #class))] - (in #Class)) - (do <>.monad - [_ (.this! (' #interface))] - (in #Interface)) - )) - (def: import_member_alias^ (Parser (Maybe Text)) (<>.maybe (do <>.monad - [_ (.this! (' #as))] + [_ (.this! (' "as"))] .local_identifier))) (def: (import_member_args^ type_vars) diff --git a/stdlib/source/library/lux/ffi.lua.lux b/stdlib/source/library/lux/ffi.lua.lux index 4d9fcf6a1..b14c2ebe3 100644 --- a/stdlib/source/library/lux/ffi.lua.lux +++ b/stdlib/source/library/lux/ffi.lua.lux @@ -100,7 +100,7 @@ (Parser Common_Method) ($_ <>.and .local_identifier - (<>.maybe (<>.after (.this! (' #as)) .local_identifier)) + (<>.maybe (<>.after (.this! (' "as")) .local_identifier)) (.tuple (<>.some ..nilable)) (<>.parses? (.this! (' "io"))) (<>.parses? (.this! (' "try"))) diff --git a/stdlib/source/library/lux/ffi.old.lux b/stdlib/source/library/lux/ffi.old.lux index a6dd4c4bf..9140ddab8 100644 --- a/stdlib/source/library/lux/ffi.old.lux +++ b/stdlib/source/library/lux/ffi.old.lux @@ -530,17 +530,17 @@ (Parser Privacy) (let [(^open ".") <>.monad] ($_ <>.or - (.this! (' #public)) - (.this! (' #private)) - (.this! (' #protected)) + (.this! (' "public")) + (.this! (' "private")) + (.this! (' "protected")) (in [])))) (def: inheritance_modifier^ (Parser Inheritance) (let [(^open ".") <>.monad] ($_ <>.or - (.this! (' #final)) - (.this! (' #abstract)) + (.this! (' "final")) + (.this! (' "abstract")) (in [])))) (def: bound_kind^ @@ -656,7 +656,7 @@ (def: annotations^' (Parser (List Annotation)) (do <>.monad - [_ (.this! (' #ann))] + [_ (.this! (' "ann"))] (.tuple (<>.some ..annotation^)))) (def: annotations^ @@ -668,7 +668,7 @@ (def: (throws_decl'^ type_vars) (-> (List Type_Parameter) (Parser (List GenericType))) (do <>.monad - [_ (.this! (' #throws))] + [_ (.this! (' "throws"))] (.tuple (<>.some (..generic_type^ type_vars))))) (def: (throws_decl^ type_vars) @@ -694,14 +694,14 @@ (def: state_modifier^ (Parser State) ($_ <>.or - (.this! (' #volatile)) - (.this! (' #final)) + (.this! (' "volatile")) + (.this! (' "final")) (\ <>.monad in []))) (def: (field_decl^ type_vars) (-> (List Type_Parameter) (Parser [Member_Declaration FieldDecl])) (<>.either (.form (do <>.monad - [_ (.this! (' #const)) + [_ (.this! (' "const")) name .local_identifier anns ..annotations^ type (..generic_type^ type_vars) @@ -736,7 +736,7 @@ (-> (List Type_Parameter) (Parser [Member_Declaration Method_Definition])) (.form (do <>.monad [pm privacy_modifier^ - strict_fp? (<>.parses? (.this! (' #strict))) + strict_fp? (<>.parses? (.this! (' "strict"))) method_vars ..type_params^ .let [total_vars (list\composite class_vars method_vars)] [_ arg_decls] (.form (<>.and (.this! (' new)) @@ -754,8 +754,8 @@ (-> (List Type_Parameter) (Parser [Member_Declaration Method_Definition])) (.form (do <>.monad [pm privacy_modifier^ - strict_fp? (<>.parses? (.this! (' #strict))) - final? (<>.parses? (.this! (' #final))) + strict_fp? (<>.parses? (.this! (' "strict"))) + final? (<>.parses? (.this! (' "final"))) method_vars ..type_params^ .let [total_vars (list\composite class_vars method_vars)] [name this_name arg_decls] (.form ($_ <>.and @@ -777,7 +777,7 @@ (def: overriden_method_def^ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad - [strict_fp? (<>.parses? (.this! (' #strict))) + [strict_fp? (<>.parses? (.this! (' "strict"))) owner_class ..class_decl^ method_vars ..type_params^ .let [total_vars (list\composite (product.right owner_class) method_vars)] @@ -801,7 +801,7 @@ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad [pm privacy_modifier^ - strict_fp? (<>.parses? (.this! (' #strict))) + strict_fp? (<>.parses? (.this! (' "strict"))) _ (.this! (' "static")) method_vars ..type_params^ .let [total_vars method_vars] @@ -820,7 +820,7 @@ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad [pm privacy_modifier^ - _ (.this! (' #abstract)) + _ (.this! (' "abstract")) method_vars ..type_params^ .let [total_vars method_vars] [name arg_decls] (.form (<>.and .local_identifier @@ -837,7 +837,7 @@ (Parser [Member_Declaration Method_Definition]) (.form (do <>.monad [pm privacy_modifier^ - _ (.this! (' #native)) + _ (.this! (' "native")) method_vars ..type_params^ .let [total_vars method_vars] [name arg_decls] (.form (<>.and .local_identifier @@ -864,20 +864,10 @@ (Parser Partial_Call) (.form (<>.and .identifier (<>.some .any)))) -(def: class_kind^ - (Parser Class_Kind) - (<>.either (do <>.monad - [_ (.this! (' #class))] - (in #Class)) - (do <>.monad - [_ (.this! (' #interface))] - (in #Interface)) - )) - (def: import_member_alias^ (Parser (Maybe Text)) (<>.maybe (do <>.monad - [_ (.this! (' #as))] + [_ (.this! (' "as"))] .local_identifier))) (def: (import_member_args^ type_vars) diff --git a/stdlib/source/library/lux/ffi.php.lux b/stdlib/source/library/lux/ffi.php.lux index 1e7f61563..7320bb059 100644 --- a/stdlib/source/library/lux/ffi.php.lux +++ b/stdlib/source/library/lux/ffi.php.lux @@ -60,7 +60,7 @@ (def: alias (Parser Alias) - (<>.after (.this! (' #as)) .local_identifier)) + (<>.after (.this! (' "as")) .local_identifier)) (type: Field [Bit Text (Maybe Alias) Nullable]) diff --git a/stdlib/source/library/lux/ffi.py.lux b/stdlib/source/library/lux/ffi.py.lux index b523ce1e4..b49d7ddf4 100644 --- a/stdlib/source/library/lux/ffi.py.lux +++ b/stdlib/source/library/lux/ffi.py.lux @@ -101,7 +101,7 @@ (Parser Common_Method) ($_ <>.and .local_identifier - (<>.maybe (<>.after (.this! (' #as)) .local_identifier)) + (<>.maybe (<>.after (.this! (' "as")) .local_identifier)) (.tuple (<>.some ..noneable)) (<>.parses? (.this! (' "io"))) (<>.parses? (.this! (' "try"))) diff --git a/stdlib/source/library/lux/ffi.rb.lux b/stdlib/source/library/lux/ffi.rb.lux index 62bafd5e5..e9a5869af 100644 --- a/stdlib/source/library/lux/ffi.rb.lux +++ b/stdlib/source/library/lux/ffi.rb.lux @@ -62,7 +62,7 @@ (def: alias (Parser Alias) - (<>.after (.this! (' #as)) .local_identifier)) + (<>.after (.this! (' "as")) .local_identifier)) (type: Field [Bit Text (Maybe Alias) Nilable]) diff --git a/stdlib/source/library/lux/ffi.scm.lux b/stdlib/source/library/lux/ffi.scm.lux index 58603cef7..fb270b39c 100644 --- a/stdlib/source/library/lux/ffi.scm.lux +++ b/stdlib/source/library/lux/ffi.scm.lux @@ -60,7 +60,7 @@ (def: alias (Parser Alias) - (<>.after (.this! (' #as)) .local_identifier)) + (<>.after (.this! (' "as")) .local_identifier)) (type: Field [Bit Text (Maybe Alias) Nilable]) diff --git a/stdlib/source/library/lux/macro.lux b/stdlib/source/library/lux/macro.lux index f98f8c452..a5be7a729 100644 --- a/stdlib/source/library/lux/macro.lux +++ b/stdlib/source/library/lux/macro.lux @@ -158,7 +158,7 @@ macro_name [module short]] (case (: (Maybe [Bit Code]) (case tokens - (^ (list [_ (#.Tag ["" "omit"])] + (^ (list [_ (#.Text "omit")] token)) (#.Some [#1 token]) diff --git a/stdlib/source/library/lux/target/jvm/loader.lux b/stdlib/source/library/lux/target/jvm/loader.lux index 796e8f0f8..daae8ca9a 100644 --- a/stdlib/source/library/lux/target/jvm/loader.lux +++ b/stdlib/source/library/lux/target/jvm/loader.lux @@ -111,7 +111,7 @@ [] (java/lang/ClassLoader (findClass self {class_name java/lang/String}) (java/lang/Class [? < java/lang/Object]) - #throws [java/lang/ClassNotFoundException] + "throws" [java/lang/ClassNotFoundException] (let [class_name (:as Text class_name) classes (|> library atom.read! io.run!)] (case (dictionary.value class_name classes) diff --git a/stdlib/source/library/lux/world/file.lux b/stdlib/source/library/lux/world/file.lux index 6e7a2e1ed..c66e0d4f9 100644 --- a/stdlib/source/library/lux/world/file.lux +++ b/stdlib/source/library/lux/world/file.lux @@ -657,18 +657,18 @@ ))) @.ruby - (as_is (ffi.import: Time #as RubyTime + (as_is (ffi.import: Time "as" RubyTime ["#::." ("static" at [Frac] RubyTime) (to_f [] Frac)]) - (ffi.import: Stat #as RubyStat + (ffi.import: Stat "as" RubyStat ["#::." (executable? [] Bit) (size Int) (mtime [] RubyTime)]) - (ffi.import: File #as RubyFile + (ffi.import: File "as" RubyFile ["#::." ("static" SEPARATOR ffi.String) ("static" open [Path ffi.String] "io" "try" RubyFile) @@ -683,14 +683,14 @@ (flush [] "io" "try" "?" Any) (close [] "io" "try" "?" Any)]) - (ffi.import: Dir #as RubyDir + (ffi.import: Dir "as" RubyDir ["#::." ("static" open [Path] "io" "try" RubyDir) (children [] "io" "try" (Array Path)) (close [] "io" "try" "?" Any)]) - (ffi.import: "fileutils" FileUtils #as RubyFileUtils + (ffi.import: "fileutils" FileUtils "as" RubyFileUtils ["#::." ("static" move [Path Path] "io" "try" "?" Any) ("static" rmdir [Path] "io" "try" "?" Any) diff --git a/stdlib/source/library/lux/world/program.lux b/stdlib/source/library/lux/world/program.lux index 9b0733ec5..1a8304c8a 100644 --- a/stdlib/source/library/lux/world/program.lux +++ b/stdlib/source/library/lux/world/program.lux @@ -130,7 +130,7 @@ (import: java/lang/System ["#::." ("static" getenv [] (java/util/Map java/lang/String java/lang/String)) - ("static" getenv #as resolveEnv [java/lang/String] "io" "?" java/lang/String) + ("static" getenv "as" resolveEnv [java/lang/String] "io" "?" java/lang/String) ("static" getProperty [java/lang/String] "?" java/lang/String) ("static" exit [int] "io" void)]) @@ -260,20 +260,20 @@ (#try.Failure _) (in default))))) - @.ruby (as_is (ffi.import: Env #as RubyEnv + @.ruby (as_is (ffi.import: Env "as" RubyEnv ["#::." ("static" keys [] (Array Text)) ("static" fetch [Text] "io" "?" Text)]) - (ffi.import: "fileutils" FileUtils #as RubyFileUtils + (ffi.import: "fileutils" FileUtils "as" RubyFileUtils ["#::." ("static" pwd Path)]) - (ffi.import: Dir #as RubyDir + (ffi.import: Dir "as" RubyDir ["#::." ("static" home Path)]) - (ffi.import: Kernel #as RubyKernel + (ffi.import: Kernel "as" RubyKernel ["#::." ("static" exit [Int] "io" Nothing)])) @@ -282,8 +282,8 @@ ... ... https://www.php.net/manual/en/function.exit.php ... (ffi.import: (getcwd [] "io" ffi.String)) ... ... https://www.php.net/manual/en/function.getcwd.php - ... (ffi.import: (getenv #as getenv/1 [ffi.String] "io" ffi.String)) - ... (ffi.import: (getenv #as getenv/0 [] "io" (Array ffi.String))) + ... (ffi.import: (getenv "as" getenv/1 [ffi.String] "io" ffi.String)) + ... (ffi.import: (getenv "as" getenv/0 [] "io" (Array ffi.String))) ... ... https://www.php.net/manual/en/function.getenv.php ... ... https://www.php.net/manual/en/function.array-keys.php ... (ffi.import: (array_keys [(Array ffi.String)] (Array ffi.String))) @@ -297,8 +297,8 @@ ... (ffi.import: (get-environment-variables [] "io" PList)) ... (ffi.import: (car [Pair] Text)) ... (ffi.import: (cdr [Pair] Text)) - ... (ffi.import: (car #as head [PList] Pair)) - ... (ffi.import: (cdr #as tail [PList] PList))) + ... (ffi.import: (car "as" head [PList] Pair)) + ... (ffi.import: (cdr "as" tail [PList] PList))) } (as_is))) diff --git a/stdlib/source/test/lux/ffi.jvm.lux b/stdlib/source/test/lux/ffi.jvm.lux index 97ecdb7a4..7557f7f9f 100644 --- a/stdlib/source/test/lux/ffi.jvm.lux +++ b/stdlib/source/test/lux/ffi.jvm.lux @@ -231,7 +231,7 @@ (actual0 [] java/lang/Long)]) (/.interface: test/TestInterface1 - ([] actual1 [java/lang/Boolean] java/lang/Long #throws [java/lang/Throwable])) + ([] actual1 [java/lang/Boolean] java/lang/Long "throws" [java/lang/Throwable])) (/.import: test/TestInterface1 ["#::." @@ -280,7 +280,7 @@ (test/TestInterface1 [] (actual1 self {throw? java/lang/Boolean}) java/lang/Long - #throws [java/lang/Throwable] + "throws" [java/lang/Throwable] (if (:as Bit throw?) (panic! "YOLO") (:as java/lang/Long @@ -340,12 +340,12 @@ example/3! example/4!)))) -(/.class: #final test/TestClass0 [test/TestInterface0] +(/.class: "final" test/TestClass0 [test/TestInterface0] ... Fields - (#private value java/lang/Long) + ("private" value java/lang/Long) ... Constructors - (#public [] (new self {value java/lang/Long}) [] - (:= ::value value)) + ("public" [] (new self {value java/lang/Long}) [] + (:= ::value value)) ... Methods (test/TestInterface0 [] (actual0 self) java/lang/Long ::value)) @@ -354,14 +354,14 @@ ["#::." (new [java/lang/Long])]) -(/.class: #final test/TestClass1 [test/TestInterface1] +(/.class: "final" test/TestClass1 [test/TestInterface1] ... Fields - (#private value java/lang/Long) + ("private" value java/lang/Long) ... Constructors - (#public [] (new self {value java/lang/Long}) [] - (:= ::value value)) + ("public" [] (new self {value java/lang/Long}) [] + (:= ::value value)) ... Methods - (test/TestInterface1 [] (actual1 self {throw? java/lang/Boolean}) java/lang/Long #throws [java/lang/Throwable] + (test/TestInterface1 [] (actual1 self {throw? java/lang/Boolean}) java/lang/Long "throws" [java/lang/Throwable] (if (:as Bit throw?) (panic! "YOLO") ::value))) @@ -370,10 +370,10 @@ ["#::." (new [java/lang/Long])]) -(/.class: #final test/TestClass2 [test/TestInterface2] +(/.class: "final" test/TestClass2 [test/TestInterface2] ... Constructors - (#public [] (new self) [] - []) + ("public" [] (new self) [] + []) ... Methods (test/TestInterface2 [a] (actual2 self {input a}) @@ -384,12 +384,12 @@ ["#::." (new [])]) -(/.class: #final (test/TestClass3 a) [(test/TestInterface3 a)] +(/.class: "final" (test/TestClass3 a) [(test/TestInterface3 a)] ... Fields - (#private value a) + ("private" value a) ... Constructors - (#public [] (new self {value a}) [] - (:= ::value value)) + ("public" [] (new self {value a}) [] + (:= ::value value)) ... Methods ((test/TestInterface3 a) [] (actual3 self) @@ -400,48 +400,48 @@ ["#::." (new [a])]) -(/.class: #final test/TestClass4 [] +(/.class: "final" test/TestClass4 [] ... Constructors - (#public [] (new self) [] - []) + ("public" [] (new self) [] + []) ... Methods - (#public (actual4 self {value java/lang/Long}) java/lang/Long - value)) + ("public" (actual4 self {value java/lang/Long}) java/lang/Long + value)) (/.import: test/TestClass4 ["#::." (new []) (actual4 [java/lang/Long] java/lang/Long)]) -(/.class: #final test/TestClass5 [] +(/.class: "final" test/TestClass5 [] ... Constructors - (#public [] (new self) [] - []) + ("public" [] (new self) [] + []) ... Methods - (#public "static" (actual5 {value java/lang/Long}) - java/lang/Long - value)) + ("public" "static" (actual5 {value java/lang/Long}) + java/lang/Long + value)) (/.import: test/TestClass5 ["#::." ("static" actual5 [java/lang/Long] java/lang/Long)]) -(/.class: #abstract test/TestClass6 [] +(/.class: "abstract" test/TestClass6 [] ... Constructors - (#public [] (new self) [] - []) + ("public" [] (new self) [] + []) ... Methods - (#public #abstract (actual6 {value java/lang/Long}) - java/lang/Long)) + ("public" "abstract" (actual6 {value java/lang/Long}) + java/lang/Long)) (/.import: test/TestClass6 ["#::." (actual6 [java/lang/Long] java/lang/Long)]) -(/.class: #final test/TestClass7 test/TestClass6 [] +(/.class: "final" test/TestClass7 test/TestClass6 [] ... Constructors - (#public [] (new self) [] - []) + ("public" [] (new self) [] + []) ... Methods (test/TestClass6 [] (actual6 self {input java/lang/Long}) @@ -452,10 +452,10 @@ ["#::." (new [])]) -(/.class: #final test/TestClass8 [test/TestInterface4] +(/.class: "final" test/TestClass8 [test/TestInterface4] ... Constructors - (#public [] (new self) [] - []) + ("public" [] (new self) [] + []) ... Methods (test/TestInterface4 [] (actual4 self {actual_left long} {actual_right long} {_ long}) @@ -468,17 +468,17 @@ ["#::." (new [])]) -(/.class: #final (test/TestClass9 a) [] +(/.class: "final" (test/TestClass9 a) [] ... Fields - (#private value9 a) + ("private" value9 a) ... Constructors - (#public [] (new self {value a}) [] - (:= ::value9 value)) + ("public" [] (new self {value a}) [] + (:= ::value9 value)) ... Methods - (#public (set_actual9 self {value a}) void - (:= ::value9 value)) - (#public (get_actual9 self) a - ::value9)) + ("public" (set_actual9 self {value a}) void + (:= ::value9 value)) + ("public" (get_actual9 self) a + ::value9)) (/.import: (test/TestClass9 a) ["#::." diff --git a/stdlib/source/test/lux/ffi.old.lux b/stdlib/source/test/lux/ffi.old.lux index 22c0a636a..1fcb84652 100644 --- a/stdlib/source/test/lux/ffi.old.lux +++ b/stdlib/source/test/lux/ffi.old.lux @@ -33,22 +33,22 @@ ["#::." (getName [] java/lang/String)]) -(/.class: #final (TestClass A) [] +(/.class: "final" (TestClass A) [] ... Fields - (#private increase java/lang/Long) - (#private counter java/lang/Long) + ("private" increase java/lang/Long) + ("private" counter java/lang/Long) ... Methods - (#public [] (new {increase java/lang/Long} {counter java/lang/Long}) [] - (exec - (:= ::increase increase) - (:= ::counter counter) - [])) - (#public (currentC self) java/lang/Long - ::counter) - (#public (upC self) void - (:= ::counter (i.+ ::increase ::counter))) - (#public (downC self) void - (:= ::counter (i.- ::increase ::counter)))) + ("public" [] (new {increase java/lang/Long} {counter java/lang/Long}) [] + (exec + (:= ::increase increase) + (:= ::counter counter) + [])) + ("public" (currentC self) java/lang/Long + ::counter) + ("public" (upC self) void + (:= ::counter (i.+ ::increase ::counter))) + ("public" (downC self) void + (:= ::counter (i.- ::increase ::counter)))) (/.import: (test/lux/ffi/TestClass a) ["#::." @@ -58,9 +58,9 @@ (downC [] void)]) (/.interface: TestInterface - ([] current [] java/lang/Long #throws [java/lang/Exception]) - ([] up [] test/lux/ffi/TestInterface #throws [java/lang/Exception]) - ([] down [] test/lux/ffi/TestInterface #throws [java/lang/Exception])) + ([] current [] java/lang/Long "throws" [java/lang/Exception]) + ([] up [] test/lux/ffi/TestInterface "throws" [java/lang/Exception]) + ([] down [] test/lux/ffi/TestInterface "throws" [java/lang/Exception])) (/.import: test/lux/ffi/TestInterface ["#::." diff --git a/stdlib/source/test/lux/macro.lux b/stdlib/source/test/lux/macro.lux index fa117e96b..ec8b70644 100644 --- a/stdlib/source/test/lux/macro.lux +++ b/stdlib/source/test/lux/macro.lux @@ -125,7 +125,7 @@ (try.else false))) (_.cover [] - (and (|> (/.single_expansion (` ( (~' #omit) (..pow/4 (~ pow/1))))) + (and (|> (/.single_expansion (` ( "omit" (..pow/4 (~ pow/1))))) (meta.result lux) (try\each (\ (list.equivalence code.equivalence) = (list))) (try.else false)) -- cgit v1.2.3