aboutsummaryrefslogtreecommitdiff
path: root/lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux
diff options
context:
space:
mode:
authorEduardo Julian2021-09-12 15:39:55 -0400
committerEduardo Julian2021-09-12 15:39:55 -0400
commit2dbbaaec93a53f8dd0b96a0028b9cf125c9066cd (patch)
tree14bc8b5abe09b46ef005c3ff7cf132f1d98ddf0d /lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux
parentdda05bca0956af5e5b3875c4cc36e61aa04772e4 (diff)
Re-named \ => # && \\ => ##
Diffstat (limited to 'lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux')
-rw-r--r--lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux76
1 files changed, 38 insertions, 38 deletions
diff --git a/lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux b/lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux
index 930e219a5..3120b66b4 100644
--- a/lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux
+++ b/lux-jvm/source/luxc/lang/translation/jvm/extension/host.lux
@@ -5,18 +5,18 @@
[abstract
["[0]" monad {"+" [do]}]]
[control
- ["[0]" maybe ("[1]\[0]" functor)]
+ ["[0]" maybe ("[1]#[0]" functor)]
["[0]" exception {"+" [exception:]}]
["[0]" function]
- ["<>" parser ("[1]\[0]" monad)
+ ["<>" parser ("[1]#[0]" monad)
["<[0]>" text]
["<[0]>" synthesis {"+" [Parser]}]]]
[data
["[0]" product]
- ["[0]" text ("[1]\[0]" equivalence)
+ ["[0]" text ("[1]#[0]" equivalence)
["%" format {"+" [format]}]]
[collection
- ["[0]" list ("[1]\[0]" monad mix)]
+ ["[0]" list ("[1]#[0]" monad mix)]
["[0]" dictionary {"+" [Dictionary]}]
["[0]" set]]]
[macro
@@ -35,7 +35,7 @@
["[0]" parser]]]]
[tool
[compiler
- ["[0]" phase ("[1]\[0]" monad)]
+ ["[0]" phase ("[1]#[0]" monad)]
[reference {"+" []}
["[0]" variable {"+" [Variable Register]}]]
[meta
@@ -570,15 +570,15 @@
(do phase.monad
[valueI (generate archive valueS)]
(`` (cond (~~ (template [<object> <primitive>]
- [(and (text\= (reflection.reflection (type.reflection <primitive>))
+ [(and (text#= (reflection.reflection (type.reflection <primitive>))
from)
- (text\= <object>
+ (text#= <object>
to))
(in (|>> valueI (_.wrap <primitive>)))
- (and (text\= <object>
+ (and (text#= <object>
from)
- (text\= (reflection.reflection (type.reflection <primitive>))
+ (text#= (reflection.reflection (type.reflection <primitive>))
to))
(in (|>> valueI (_.unwrap <primitive>)))]
@@ -735,8 +735,8 @@
(function (_ extension_name generate archive [class method outputT inputsTS])
(do [! phase.monad]
[inputsTI (monad.each ! (generate_input generate archive) inputsTS)]
- (in (|>> (_.fuse (list\each product.right inputsTI))
- (_.INVOKESTATIC class method (type.method [(list) (list\each product.left inputsTI) outputT (list)]))
+ (in (|>> (_.fuse (list#each product.right inputsTI))
+ (_.INVOKESTATIC class method (type.method [(list) (list#each product.left inputsTI) outputT (list)]))
(prepare_output outputT)))))]))
(template [<name> <invoke>]
@@ -750,10 +750,10 @@
inputsTI (monad.each ! (generate_input generate archive) inputsTS)]
(in (|>> objectI
(_.CHECKCAST class)
- (_.fuse (list\each product.right inputsTI))
+ (_.fuse (list#each product.right inputsTI))
(<invoke> class method
(type.method [(list)
- (list\each product.left inputsTI)
+ (list#each product.left inputsTI)
outputT
(list)]))
(prepare_output outputT)))))]))]
@@ -772,8 +772,8 @@
[inputsTI (monad.each ! (generate_input generate archive) inputsTS)]
(in (|>> (_.NEW class)
_.DUP
- (_.fuse (list\each product.right inputsTI))
- (_.INVOKESPECIAL class "<init>" (type.method [(list) (list\each product.left inputsTI) type.void (list)]))))))]))
+ (_.fuse (list#each product.right inputsTI))
+ (_.INVOKESPECIAL class "<init>" (type.method [(list) (list#each product.left inputsTI) type.void (list)]))))))]))
(def: member_bundle
Bundle
@@ -886,12 +886,12 @@
[synthesis.#Access])
{synthesis.#Bit_Fork when then else}
- {synthesis.#Bit_Fork when (recur then) (maybe\each recur else)}
+ {synthesis.#Bit_Fork when (recur then) (maybe#each recur else)}
(^template [<tag>]
[{<tag> [[test then] elses]}
{<tag> [[test (recur then)]
- (list\each (function (_ [else_test else_then])
+ (list#each (function (_ [else_test else_then])
[else_test (recur else_then)])
elses)]}])
([synthesis.#I64_Fork]
@@ -913,7 +913,7 @@
(synthesis.variant [lefts right? (recur sub)])
(^ (synthesis.tuple members))
- (synthesis.tuple (list\each recur members))
+ (synthesis.tuple (list#each recur members))
(^ (synthesis.variable var))
(|> mapping
@@ -934,13 +934,13 @@
(synthesis.branch/get [path (recur recordS)])
(^ (synthesis.loop/scope [offset initsS+ bodyS]))
- (synthesis.loop/scope [offset (list\each recur initsS+) (recur bodyS)])
+ (synthesis.loop/scope [offset (list#each recur initsS+) (recur bodyS)])
(^ (synthesis.loop/recur updatesS+))
- (synthesis.loop/recur (list\each recur updatesS+))
+ (synthesis.loop/recur (list#each recur updatesS+))
(^ (synthesis.function/abstraction [environment arity bodyS]))
- (synthesis.function/abstraction [(list\each (function (_ captured)
+ (synthesis.function/abstraction [(list#each (function (_ captured)
(case captured
(^ (synthesis.variable var))
(|> mapping
@@ -955,10 +955,10 @@
bodyS])
(^ (synthesis.function/apply [functionS inputsS+]))
- (synthesis.function/apply [(recur functionS) (list\each recur inputsS+)])
+ (synthesis.function/apply [(recur functionS) (list#each recur inputsS+)])
{synthesis.#Extension [name inputsS+]}
- {synthesis.#Extension [name (list\each recur inputsS+)]})))
+ {synthesis.#Extension [name (list#each recur inputsS+)]})))
(def: $Object
(type.class "java.lang.Object" (list)))
@@ -975,15 +975,15 @@
(let [store_capturedI (|> env
list.size
list.indices
- (list\each (.function (_ register)
+ (list#each (.function (_ register)
(|>> (_.ALOAD 0)
(_.ALOAD (++ register))
(_.PUTFIELD class (///reference.foreign_name register) $Object))))
_.fuse)]
(_def.method #$.Public $.noneM "<init>" (anonymous_init_method env)
(|>> (_.ALOAD 0)
- ((_.fuse (list\each product.right inputsTI)))
- (_.INVOKESPECIAL super_class "<init>" (type.method [(list) (list\each product.left inputsTI) type.void (list)]))
+ ((_.fuse (list#each product.right inputsTI)))
+ (_.INVOKESPECIAL super_class "<init>" (type.method [(list) (list#each product.left inputsTI) type.void (list)]))
store_capturedI
_.RETURN))))
@@ -1013,7 +1013,7 @@
(_.wrap <type>)
(_.ASTORE lux_register))]]]
(`` (cond (~~ (template [<shift> <load> <type>]
- [(\ type.equivalence = <type> argumentT)
+ [(# type.equivalence = <type> argumentT)
(wrap_primitive <shift> <load> <type>)]
[1 _.ILOAD type.boolean]
@@ -1024,14 +1024,14 @@
[1 _.FLOAD type.float]
[2 _.LLOAD type.long]))
- ... (\ type.equivalence = type.double argumentT)
+ ... (# type.equivalence = type.double argumentT)
(wrap_primitive 2 _.DLOAD type.double))))))
(def: .public (prepare_arguments offset types)
(-> Nat (List (Type Value)) Inst)
(|> types
list.enumeration
- (list\mix (function (_ [lux_register type] [jvm_register before])
+ (list#mix (function (_ [lux_register type] [jvm_register before])
(let [[jvm_register' after] (prepare_argument (n.+ offset lux_register) type jvm_register)]
[jvm_register' (|>> before after)]))
(: [Register Inst] [offset (|>>)]))
@@ -1059,7 +1059,7 @@
[(|>> (_.unwrap <type>)
<return>)]]
(`` (cond (~~ (template [<return> <type>]
- [(\ type.equivalence = <type> returnT)
+ [(# type.equivalence = <type> returnT)
(unwrap_primitive <return> <type>)]
[_.IRETURN type.boolean]
@@ -1070,7 +1070,7 @@
[_.FRETURN type.float]
[_.LRETURN type.long]))
- ... (\ type.equivalence = type.double returnT)
+ ... (# type.equivalence = type.double returnT)
(unwrap_primitive _.DRETURN type.double)))))))
(def: class::anonymous
@@ -1092,26 +1092,26 @@
class (type.class anonymous_class_name (list))
total_environment (|> overriden_methods
... Get all the environments.
- (list\each product.left)
+ (list#each product.left)
... Combine them.
- list\conjoint
+ list#conjoint
... Remove duplicates.
(set.of_list synthesis.hash)
set.list)
global_mapping (|> total_environment
... Give them names as "foreign" variables.
list.enumeration
- (list\each (function (_ [id capture])
+ (list#each (function (_ [id capture])
[capture {variable.#Foreign id}]))
(dictionary.of_list synthesis.hash))
- normalized_methods (list\each (function (_ [environment
+ normalized_methods (list#each (function (_ [environment
[ownerT name
strict_fp? annotations vars
self_name arguments returnT exceptionsT
body]])
(let [local_mapping (|> environment
list.enumeration
- (list\each (function (_ [foreign_id capture])
+ (list#each (function (_ [foreign_id capture])
[(synthesis.variable/foreign foreign_id)
(|> global_mapping
(dictionary.value capture)
@@ -1131,7 +1131,7 @@
(do !
[bodyG (generation.with_context artifact_id
(generate archive bodyS))
- .let [argumentsT (list\each product.right arguments)]]
+ .let [argumentsT (list#each product.right arguments)]]
(in (_def.method #$.Public
(if strict_fp?
($_ $.++M $.finalM $.strictM)
@@ -1141,7 +1141,7 @@
(|>> (prepare_arguments 1 argumentsT)
bodyG
(returnI returnT)))))))
- (\ ! each _def.fuse))
+ (# ! each _def.fuse))
.let [directive [anonymous_class_name
(_def.class #$.V1_6 #$.Public $.finalC
anonymous_class_name (list)