aboutsummaryrefslogtreecommitdiff
path: root/lux-jvm/source/luxc/lang/host
diff options
context:
space:
mode:
Diffstat (limited to 'lux-jvm/source/luxc/lang/host')
-rw-r--r--lux-jvm/source/luxc/lang/host/jvm.lux34
-rw-r--r--lux-jvm/source/luxc/lang/host/jvm/def.lux14
-rw-r--r--lux-jvm/source/luxc/lang/host/jvm/inst.lux44
3 files changed, 46 insertions, 46 deletions
diff --git a/lux-jvm/source/luxc/lang/host/jvm.lux b/lux-jvm/source/luxc/lang/host/jvm.lux
index 5c854d646..a9b73c8b0 100644
--- a/lux-jvm/source/luxc/lang/host/jvm.lux
+++ b/lux-jvm/source/luxc/lang/host/jvm.lux
@@ -36,22 +36,22 @@
["#::."
(new [])])
-(type: #export Def
+(type: .public Def
(-> org/objectweb/asm/ClassWriter org/objectweb/asm/ClassWriter))
-(type: #export Inst
+(type: .public Inst
(-> org/objectweb/asm/MethodVisitor org/objectweb/asm/MethodVisitor))
-(type: #export Label
+(type: .public Label
org/objectweb/asm/Label)
-(type: #export Visibility
+(type: .public Visibility
#Public
#Protected
#Private
#Default)
-(type: #export Version
+(type: .public Version
#V1_1
#V1_2
#V1_3
@@ -61,20 +61,20 @@
#V1_7
#V1_8)
-(type: #export ByteCode
+(type: .public ByteCode
Binary)
-(type: #export Definition
+(type: .public Definition
[Text ByteCode])
-(type: #export Anchor
+(type: .public Anchor
[Label Register])
-(type: #export Host
+(type: .public Host
(generation.Host Inst Definition))
(template [<name> <base>]
- [(type: #export <name>
+ [(type: .public <name>
(<base> ..Anchor ..Inst ..Definition))]
[State generation.State]
@@ -85,7 +85,7 @@
[Extender generation.Extender]
)
-(type: #export (Generator i)
+(type: .public (Generator i)
(-> Phase Archive i (Operation Inst)))
(syntax: (config: {type <code>.local_identifier}
@@ -98,23 +98,23 @@
g!_left (code.local_identifier "_left")
g!_right (code.local_identifier "_right")
g!options+ (list/map (function (_ option)
- (` (def: (~' #export) (~ (code.local_identifier option))
+ (` (def: .public (~ (code.local_identifier option))
(~ g!type)
(|> (~ g!none)
(set@ (~ (code.local_tag option)) #1)))))
options)]
- (in (list& (` (type: (~' #export) (~ g!type)
+ (in (list& (` (type: .public (~ g!type)
(~ (code.record (list/map (function (_ tag)
[tag (` .Bit)])
g!tags+)))))
- (` (def: (~' #export) (~ g!none)
+ (` (def: .public (~ g!none)
(~ g!type)
(~ (code.record (list/map (function (_ tag)
[tag (` #0)])
g!tags+)))))
- (` (def: (~' #export) ((~ (code.local_identifier ++)) (~ g!_left) (~ g!_right))
+ (` (def: .public ((~ (code.local_identifier ++)) (~ g!_left) (~ g!_right))
(-> (~ g!type) (~ g!type) (~ g!type))
(~ (code.record (list/map (function (_ tag)
[tag (` (or (get@ (~ tag) (~ g!_left))
@@ -127,11 +127,11 @@
(config: Method_Config noneM ++M [finalM staticM synchronizedM strictM])
(config: Field_Config noneF ++F [finalF staticF transientF volatileF])
-(def: #export new_label
+(def: .public new_label
(-> Any Label)
(function (_ _)
(org/objectweb/asm/Label::new)))
-(def: #export (simple_class name)
+(def: .public (simple_class name)
(-> Text (Type Class))
(type.class name (list)))
diff --git a/lux-jvm/source/luxc/lang/host/jvm/def.lux b/lux-jvm/source/luxc/lang/host/jvm/def.lux
index e1e60179f..939a8cb91 100644
--- a/lux-jvm/source/luxc/lang/host/jvm/def.lux
+++ b/lux-jvm/source/luxc/lang/host/jvm/def.lux
@@ -166,7 +166,7 @@
(def: binary_name (|>> name.internal name.read))
(template [<name> <flag>]
- [(def: #export (<name> version visibility config name constraints super interfaces
+ [(def: .public (<name> version visibility config name constraints super interfaces
definitions)
(-> //.Version //.Visibility //.Class_Config Text (List Constraint) (Type Class) (List (Type Class)) //.Def
(ffi.type [byte]))
@@ -195,7 +195,7 @@
(Type Class)
(type.class "java.lang.Object" (list)))
-(def: #export (interface version visibility config name constraints interfaces
+(def: .public (interface version visibility config name constraints interfaces
definitions)
(-> //.Version //.Visibility //.Class_Config Text (List Constraint) (List (Type Class)) //.Def
(ffi.type [byte]))
@@ -216,7 +216,7 @@
_ (org/objectweb/asm/ClassWriter::visitEnd writer)]
(org/objectweb/asm/ClassWriter::toByteArray writer)))
-(def: #export (method visibility config name type then)
+(def: .public (method visibility config name type then)
(-> //.Visibility //.Method_Config Text (Type Method) //.Inst
//.Def)
(function (_ writer)
@@ -234,7 +234,7 @@
_ (org/objectweb/asm/MethodVisitor::visitEnd =method)]
writer)))
-(def: #export (abstract_method visibility config name type)
+(def: .public (abstract_method visibility config name type)
(-> //.Visibility //.Method_Config Text (Type Method)
//.Def)
(function (_ writer)
@@ -250,7 +250,7 @@
_ (org/objectweb/asm/MethodVisitor::visitEnd =method)]
writer)))
-(def: #export (field visibility config name type)
+(def: .public (field visibility config name type)
(-> //.Visibility //.Field_Config Text (Type Value) //.Def)
(function (_ writer)
(let [=field (do_to (org/objectweb/asm/ClassWriter::visitField ($_ i.+
@@ -265,7 +265,7 @@
writer)))
(template [<name> <lux_type> <jvm_type> <prepare>]
- [(def: #export (<name> visibility config name value)
+ [(def: .public (<name> visibility config name value)
(-> //.Visibility //.Field_Config Text <lux_type> //.Def)
(function (_ writer)
(let [=field (do_to (org/objectweb/asm/ClassWriter::visitField ($_ i.+
@@ -290,7 +290,7 @@
[string_field Text (type.class "java.lang.String" (list)) function.identity]
)
-(def: #export (fuse defs)
+(def: .public (fuse defs)
(-> (List //.Def) //.Def)
(case defs
#.End
diff --git a/lux-jvm/source/luxc/lang/host/jvm/inst.lux b/lux-jvm/source/luxc/lang/host/jvm/inst.lux
index ea68f2680..1a2c811a3 100644
--- a/lux-jvm/source/luxc/lang/host/jvm/inst.lux
+++ b/lux-jvm/source/luxc/lang/host/jvm/inst.lux
@@ -149,17 +149,17 @@
])
## [Insts]
-(def: #export make_label
+(def: .public make_label
(All [s] (Operation s org/objectweb/asm/Label))
(function (_ state)
(#try.Success [state (org/objectweb/asm/Label::new)])))
-(def: #export (with_label action)
+(def: .public (with_label action)
(All [a] (-> (-> org/objectweb/asm/Label a) a))
(action (org/objectweb/asm/Label::new)))
(template [<name> <type> <prepare>]
- [(def: #export (<name> value)
+ [(def: .public (<name> value)
(-> <type> Inst)
(function (_ visitor)
(do_to visitor
@@ -177,7 +177,7 @@
(`` ((~~ (template.identifier ["org/objectweb/asm/Opcodes::" short])))))
(template [<constant>]
- [(def: #export <constant>
+ [(def: .public <constant>
Inst
(function (_ visitor)
(do_to visitor
@@ -189,14 +189,14 @@
[DCONST_0] [DCONST_1]
)
-(def: #export NULL
+(def: .public NULL
Inst
(function (_ visitor)
(do_to visitor
(org/objectweb/asm/MethodVisitor::visitInsn (!prefix ACONST_NULL)))))
(template [<constant>]
- [(def: #export (<constant> constant)
+ [(def: .public (<constant> constant)
(-> Int Inst)
(function (_ visitor)
(do_to visitor
@@ -207,7 +207,7 @@
)
(template [<name>]
- [(def: #export <name>
+ [(def: .public <name>
Inst
(function (_ visitor)
(do_to visitor
@@ -267,10 +267,10 @@
[RETURN] [IRETURN] [LRETURN] [FRETURN] [DRETURN] [ARETURN]
)
-(type: #export Register Nat)
+(type: .public Register Nat)
(template [<name>]
- [(def: #export (<name> register)
+ [(def: .public (<name> register)
(-> Register Inst)
(function (_ visitor)
(do_to visitor
@@ -282,7 +282,7 @@
)
(template [<name> <inst>]
- [(def: #export (<name> class field type)
+ [(def: .public (<name> class field type)
(-> (Type Class) Text (Type Value) Inst)
(function (_ visitor)
(do_to visitor
@@ -297,7 +297,7 @@
(template [<category> <instructions>+]
[(`` (template [<name> <inst>]
- [(def: #export (<name> class)
+ [(def: .public (<name> class)
(-> (Type <category>) Inst)
(function (_ visitor)
(do_to visitor
@@ -314,7 +314,7 @@
[INSTANCEOF org/objectweb/asm/Opcodes::INSTANCEOF]]]
)
-(def: #export (NEWARRAY type)
+(def: .public (NEWARRAY type)
(-> (Type Primitive) Inst)
(function (_ visitor)
(do_to visitor
@@ -334,7 +334,7 @@
(undefined)))))))
(template [<name> <inst> <interface?>]
- [(def: #export (<name> class method_name method)
+ [(def: .public (<name> class method_name method)
(-> (Type Class) Text (Type Method) Inst)
(function (_ visitor)
(do_to visitor
@@ -351,7 +351,7 @@
)
(template [<name>]
- [(def: #export (<name> @where)
+ [(def: .public (<name> @where)
(-> //.Label Inst)
(function (_ visitor)
(do_to visitor
@@ -364,7 +364,7 @@
[GOTO]
)
-(def: #export (LOOKUPSWITCH default keys+labels)
+(def: .public (LOOKUPSWITCH default keys+labels)
(-> //.Label (List [Int //.Label]) Inst)
(function (_ visitor)
(let [keys+labels (list.sort (function (_ left right)
@@ -384,7 +384,7 @@
(do_to visitor
(org/objectweb/asm/MethodVisitor::visitLookupSwitchInsn default keys_array labels_array)))))
-(def: #export (TABLESWITCH min max default labels)
+(def: .public (TABLESWITCH min max default labels)
(-> Int Int //.Label (List //.Label) Inst)
(function (_ visitor)
(let [num_labels (list.size labels)
@@ -399,19 +399,19 @@
(do_to visitor
(org/objectweb/asm/MethodVisitor::visitTableSwitchInsn min max default labels_array)))))
-(def: #export (try @from @to @handler exception)
+(def: .public (try @from @to @handler exception)
(-> //.Label //.Label //.Label (Type Class) Inst)
(function (_ visitor)
(do_to visitor
(org/objectweb/asm/MethodVisitor::visitTryCatchBlock @from @to @handler (..class_name exception)))))
-(def: #export (label @label)
+(def: .public (label @label)
(-> //.Label Inst)
(function (_ visitor)
(do_to visitor
(org/objectweb/asm/MethodVisitor::visitLabel @label))))
-(def: #export (array elementT)
+(def: .public (array elementT)
(-> (Type Value) Inst)
(case (type.primitive? elementT)
(#.Left elementT)
@@ -445,18 +445,18 @@
"longValue" "floatValue" "doubleValue" "charValue"]
)
-(def: #export (wrap type)
+(def: .public (wrap type)
(-> (Type Primitive) Inst)
(let [wrapper (type.class (primitive_wrapper type) (list))]
(INVOKESTATIC wrapper "valueOf" (type.method [(list) (list type) wrapper (list)]))))
-(def: #export (unwrap type)
+(def: .public (unwrap type)
(-> (Type Primitive) Inst)
(let [wrapper (type.class (primitive_wrapper type) (list))]
(|>> (CHECKCAST wrapper)
(INVOKEVIRTUAL wrapper (primitive_unwrap type) (type.method [(list) (list) type (list)])))))
-(def: #export (fuse insts)
+(def: .public (fuse insts)
(-> (List Inst) Inst)
(case insts
#.End