aboutsummaryrefslogtreecommitdiff
path: root/lux-r
diff options
context:
space:
mode:
authorEduardo Julian2021-08-09 23:02:01 -0400
committerEduardo Julian2021-08-09 23:02:01 -0400
commit464b6e8f5e6c62f58fa8c7ff61ab2ad215e98bd1 (patch)
tree1ae9d95956cee4251cd29a3e24c246c4360d567d /lux-r
parentf621a133e6e0a516c0586270fea8eaffb4829d82 (diff)
Improved single-line comment syntax (from "##" to "...").
Diffstat (limited to 'lux-r')
-rw-r--r--lux-r/source/luxc/lang/synthesis/variable.lux14
-rw-r--r--lux-r/source/program.lux186
-rw-r--r--lux-r/source/test/program.lux2
3 files changed, 101 insertions, 101 deletions
diff --git a/lux-r/source/luxc/lang/synthesis/variable.lux b/lux-r/source/luxc/lang/synthesis/variable.lux
index f6a45b02e..932cb3dcb 100644
--- a/lux-r/source/luxc/lang/synthesis/variable.lux
+++ b/lux-r/source/luxc/lang/synthesis/variable.lux
@@ -89,10 +89,10 @@
))]
(s.to-list tracker)))
-## (def: (optimize-register-use current-arity [pathS bodyS])
-## (-> ls.Arity [ls.Path ls.Synthesis] [ls.Path ls.Synthesis])
-## (let [bound (bound-vars pathS)
-## unused (unused-vars current-arity bound bodyS)
-## adjusted (adjust-vars unused bound)]
-## [(|> pathS (clean-pattern adjusted) simplify-pattern)
-## (clean-expression adjusted bodyS)]))
+... (def: (optimize-register-use current-arity [pathS bodyS])
+... (-> ls.Arity [ls.Path ls.Synthesis] [ls.Path ls.Synthesis])
+... (let [bound (bound-vars pathS)
+... unused (unused-vars current-arity bound bodyS)
+... adjusted (adjust-vars unused bound)]
+... [(|> pathS (clean-pattern adjusted) simplify-pattern)
+... (clean-expression adjusted bodyS)]))
diff --git a/lux-r/source/program.lux b/lux-r/source/program.lux
index a42c5f06d..19b417b4d 100644
--- a/lux-r/source/program.lux
+++ b/lux-r/source/program.lux
@@ -171,104 +171,104 @@
[cannot_apply_a_non_function]
)
-## (def: host_bit
-## (-> Bit org/armedbear/lisp/LispObject)
-## (|>> (case> #0 (org/armedbear/lisp/Nil::NIL)
-## #1 (org/armedbear/lisp/Symbol::T))))
+... (def: host_bit
+... (-> Bit org/armedbear/lisp/LispObject)
+... (|>> (case> #0 (org/armedbear/lisp/Nil::NIL)
+... #1 (org/armedbear/lisp/Symbol::T))))
(syntax: (%%code term)
(wrap (list (code.text (%.code term)))))
(def: (host_value value)
(-> Any org/renjin/sexp/SEXP)
- (let [## to_sub (: (-> Any org/armedbear/lisp/LispObject)
- ## (function (_ sub_value)
- ## (let [sub_value (:as java/lang/Object sub_value)]
- ## (`` (<| (~~ (template [<type> <then>]
- ## [(case (ffi.check <type> sub_value)
- ## (#.Some sub_value)
- ## (`` (|> sub_value (~~ (template.splice <then>))))
- ## #.None)]
-
- ## [[java/lang/Object] [host_value]]
- ## [java/lang/Boolean [..host_bit]]
- ## [java/lang/Integer [java/lang/Integer::longValue org/armedbear/lisp/Fixnum::getInstance]]
- ## [java/lang/Long [org/armedbear/lisp/Bignum::getInstance]]
- ## [java/lang/Double [org/armedbear/lisp/DoubleFloat::new]]
- ## [java/lang/String [org/armedbear/lisp/SimpleString::new]]
- ## ))
- ## ## else
- ## (:as org/armedbear/lisp/LispObject sub_value))))))
+ (let [... to_sub (: (-> Any org/armedbear/lisp/LispObject)
+ ... (function (_ sub_value)
+ ... (let [sub_value (:as java/lang/Object sub_value)]
+ ... (`` (<| (~~ (template [<type> <then>]
+ ... [(case (ffi.check <type> sub_value)
+ ... (#.Some sub_value)
+ ... (`` (|> sub_value (~~ (template.splice <then>))))
+ ... #.None)]
+
+ ... [[java/lang/Object] [host_value]]
+ ... [java/lang/Boolean [..host_bit]]
+ ... [java/lang/Integer [java/lang/Integer::longValue org/armedbear/lisp/Fixnum::getInstance]]
+ ... [java/lang/Long [org/armedbear/lisp/Bignum::getInstance]]
+ ... [java/lang/Double [org/armedbear/lisp/DoubleFloat::new]]
+ ... [java/lang/String [org/armedbear/lisp/SimpleString::new]]
+ ... ))
+ ... ... else
+ ... (:as org/armedbear/lisp/LispObject sub_value))))))
]
(`` (macro.log_expand_once!
(ffi.object []
- ## org/renjin/sexp/AbstractSEXP
+ ... org/renjin/sexp/AbstractSEXP
org/renjin/sexp/ListVector
- ## java/lang/Object
- [ ## program/LuxADT
- ## org/renjin/sexp/SEXP
+ ... java/lang/Object
+ [ ... program/LuxADT
+ ... org/renjin/sexp/SEXP
]
[{[org/renjin/sexp/SEXP]
(ffi.array org/renjin/sexp/SEXP 0)
- ## (java/util/List java/lang/Object)
- ## (:assume (..fake_list []))
+ ... (java/util/List java/lang/Object)
+ ... (:assume (..fake_list []))
}]
- ## Methods
- ## (program/LuxADT
- ## [] (getValue self) java/lang/Object
- ## (:as java/lang/Object value))
-
- ## (org/renjin/sexp/AbstractSEXP
- ## [] (eval self {context org/renjin/eval/Context} {environment org/renjin/sexp/Environment})
- ## org/renjin/sexp/SEXP
- ## (exec
- ## ("lux io log" (exception.report
- ## ["@@" "eval"]
- ## ["context" (debug.inspect context)]
- ## ["environment" (debug.inspect environment)]))
- ## self))
-
- ## (org/renjin/sexp/AbstractSEXP
- ## [] (getAttributes self)
- ## org/renjin/sexp/AttributeMap
- ## (org/renjin/sexp/AttributeMap::EMPTY))
-
- ## (org/renjin/sexp/AbstractSEXP
- ## [] (getTypeName self)
- ## java/lang/String
- ## "LUX")
+ ... Methods
+ ... (program/LuxADT
+ ... [] (getValue self) java/lang/Object
+ ... (:as java/lang/Object value))
+
+ ... (org/renjin/sexp/AbstractSEXP
+ ... [] (eval self {context org/renjin/eval/Context} {environment org/renjin/sexp/Environment})
+ ... org/renjin/sexp/SEXP
+ ... (exec
+ ... ("lux io log" (exception.report
+ ... ["@@" "eval"]
+ ... ["context" (debug.inspect context)]
+ ... ["environment" (debug.inspect environment)]))
+ ... self))
+
+ ... (org/renjin/sexp/AbstractSEXP
+ ... [] (getAttributes self)
+ ... org/renjin/sexp/AttributeMap
+ ... (org/renjin/sexp/AttributeMap::EMPTY))
+
+ ... (org/renjin/sexp/AbstractSEXP
+ ... [] (getTypeName self)
+ ... java/lang/String
+ ... "LUX")
(org/renjin/sexp/ListVector
[] (get self {_ int})
org/renjin/sexp/SEXP
(exec
- ## ("lux io log" (..%%code <call>))
+ ... ("lux io log" (..%%code <call>))
_jvm_this))
(org/renjin/sexp/ListVector
[] (get self {_ java/lang/String})
org/renjin/sexp/SEXP
(exec
- ## ("lux io log" (..%%code <call>))
+ ... ("lux io log" (..%%code <call>))
_jvm_this))
(~~ (template [<call> <output>]
[(org/renjin/sexp/ListVector
- ## org/renjin/sexp/AbstractSEXP
- ## org/renjin/sexp/SEXP
+ ... org/renjin/sexp/AbstractSEXP
+ ... org/renjin/sexp/SEXP
[] <call>
<output>
- ## (exec
- ## ## ("lux io log" (..%%code <call>))
- ## (error! (..%%code <call>)))
+ ... (exec
+ ... ... ("lux io log" (..%%code <call>))
+ ... (error! (..%%code <call>)))
(error! (..%%code <call>)))]
- ## org/renjin/sexp/ListVector
+ ... org/renjin/sexp/ListVector
[(accept self {_ org/renjin/sexp/SexpVisitor}) void]
[(anyNA self) boolean]
[(contains self {_ org/renjin/sexp/Vector} {_ int}) boolean]
- ## [(copyTo self {_ [double]} {_ int} {_ int}) void]
+ ... [(copyTo self {_ [double]} {_ int} {_ int}) void]
[(equals self {_ java/lang/Object}) boolean]
[(getComputationDepth self) int]
@@ -315,31 +315,31 @@
[(toArrayUnsafe self) [org/renjin/sexp/SEXP]]
[(toString self) java/lang/String]
- ## org/renjin/sexp/AbstractSEXP
- ## org/renjin/sexp/SEXP
- ## [(accept self {_ org/renjin/sexp/SexpVisitor}) void]
- ## [(asInt self) int]
- ## [(asLogical self) org/renjin/sexp/Logical]
- ## [(asReal self) double]
- ## [(asString self) java/lang/String]
- ## [(force self {_ org/renjin/eval/Context}) org/renjin/sexp/SEXP]
- ## [(getAttribute self {_ org/renjin/sexp/Symbol}) org/renjin/sexp/SEXP]
- ## [(getElementAsSEXP self {_ int}) org/renjin/sexp/SEXP]
- ## [(getImplicitClass self) java/lang/String]
- ## ## [(getIndexByName self {_ java/lang/String}) int]
- ## [(getName self {_ int}) java/lang/String]
- ## [(getNames self) org/renjin/sexp/AtomicVector]
- ## [(getS3Class self) org/renjin/sexp/StringVector]
- ## ## [(hasAttributes self) boolean]
- ## [(hasNames self) boolean]
- ## [(inherits self {_ java/lang/String}) boolean]
- ## [(isNumeric self) boolean]
- ## ## [(isObject self) boolean]
- ## [(length self) int]
- ## ## [(setAttribute self {_ java/lang/String} {_ org/renjin/sexp/SEXP}) org/renjin/sexp/SEXP]
- ## [(setAttribute self {_ org/renjin/sexp/Symbol} {_ org/renjin/sexp/SEXP}) org/renjin/sexp/SEXP]
- ## [(setAttributes self {_ org/renjin/sexp/AttributeMap$Builder}) org/renjin/sexp/SEXP]
- ## [(setAttributes self {_ org/renjin/sexp/AttributeMap}) org/renjin/sexp/SEXP]
+ ... org/renjin/sexp/AbstractSEXP
+ ... org/renjin/sexp/SEXP
+ ... [(accept self {_ org/renjin/sexp/SexpVisitor}) void]
+ ... [(asInt self) int]
+ ... [(asLogical self) org/renjin/sexp/Logical]
+ ... [(asReal self) double]
+ ... [(asString self) java/lang/String]
+ ... [(force self {_ org/renjin/eval/Context}) org/renjin/sexp/SEXP]
+ ... [(getAttribute self {_ org/renjin/sexp/Symbol}) org/renjin/sexp/SEXP]
+ ... [(getElementAsSEXP self {_ int}) org/renjin/sexp/SEXP]
+ ... [(getImplicitClass self) java/lang/String]
+ ... ... [(getIndexByName self {_ java/lang/String}) int]
+ ... [(getName self {_ int}) java/lang/String]
+ ... [(getNames self) org/renjin/sexp/AtomicVector]
+ ... [(getS3Class self) org/renjin/sexp/StringVector]
+ ... ... [(hasAttributes self) boolean]
+ ... [(hasNames self) boolean]
+ ... [(inherits self {_ java/lang/String}) boolean]
+ ... [(isNumeric self) boolean]
+ ... ... [(isObject self) boolean]
+ ... [(length self) int]
+ ... ... [(setAttribute self {_ java/lang/String} {_ org/renjin/sexp/SEXP}) org/renjin/sexp/SEXP]
+ ... [(setAttribute self {_ org/renjin/sexp/Symbol} {_ org/renjin/sexp/SEXP}) org/renjin/sexp/SEXP]
+ ... [(setAttributes self {_ org/renjin/sexp/AttributeMap$Builder}) org/renjin/sexp/SEXP]
+ ... [(setAttributes self {_ org/renjin/sexp/AttributeMap}) org/renjin/sexp/SEXP]
))
)))))
@@ -408,7 +408,7 @@
(def: (read host_object)
(Reader java/lang/Object)
(exec
- ## ("lux io log" (exception.construct ..unknown_kind_of_object [host_object]))
+ ... ("lux io log" (exception.construct ..unknown_kind_of_object [host_object]))
(`` (<| (case (ffi.check org/renjin/sexp/ListVector host_object)
(#.Some host_object)
(<| (case (..read_variant read host_object)
@@ -437,10 +437,10 @@
org/renjin/sexp/Logical::toBooleanStrict
#try.Success]]
[org/renjin/sexp/Closure [#try.Success]]
- ## [org/armedbear/lisp/DoubleFloat [org/armedbear/lisp/DoubleFloat::doubleValue #try.Success]]
- ## [program/LuxADT [program/LuxADT::getValue #try.Success]]
+ ... [org/armedbear/lisp/DoubleFloat [org/armedbear/lisp/DoubleFloat::doubleValue #try.Success]]
+ ... [program/LuxADT [program/LuxADT::getValue #try.Success]]
))
- ## else
+ ... else
(exception.throw ..unknown_kind_of_object [host_object])
))))
@@ -506,7 +506,7 @@
(def: (execute! input)
(exec
("lux io log" "@execute!")
- ## ("lux io log" (_.code input))
+ ... ("lux io log" (_.code input))
(javax/script/ScriptEngine::eval (_.code input) interpreter)))
(def: (define! context input)
@@ -515,7 +515,7 @@
(do try.monad
[#let [definition (_.set! $global input)]
#let [_ ("lux io log" "@define! 0")
- ## _ ("lux io log" (_.code definition))
+ ... _ ("lux io log" (_.code definition))
]
_ (javax/script/ScriptEngine::eval (_.code definition) interpreter)
#let [_ ("lux io log" "@define! 1")]
@@ -554,7 +554,7 @@
(for {@.old
(def: extender
Extender
- ## TODO: Stop relying on coercions ASAP.
+ ... TODO: Stop relying on coercions ASAP.
(<| (:as Extender)
(function (@self handler))
(:as Handler)
diff --git a/lux-r/source/test/program.lux b/lux-r/source/test/program.lux
index 270f9005d..46e2a2b71 100644
--- a/lux-r/source/test/program.lux
+++ b/lux-r/source/test/program.lux
@@ -13,6 +13,6 @@
(program: args
(<| io.io
_.run!
- ## (_.times 100)
+ ... (_.times 100)
(_.seed 1985013625126912890)
(compositor.spec /.jvm /.bundle /.expander /.program)))