aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/program
diff options
context:
space:
mode:
authorEduardo Julian2021-08-09 23:02:01 -0400
committerEduardo Julian2021-08-09 23:02:01 -0400
commit464b6e8f5e6c62f58fa8c7ff61ab2ad215e98bd1 (patch)
tree1ae9d95956cee4251cd29a3e24c246c4360d567d /stdlib/source/program
parentf621a133e6e0a516c0586270fea8eaffb4829d82 (diff)
Improved single-line comment syntax (from "##" to "...").
Diffstat (limited to 'stdlib/source/program')
-rw-r--r--stdlib/source/program/aedifex/artifact.lux2
-rw-r--r--stdlib/source/program/aedifex/artifact/extension.lux2
-rw-r--r--stdlib/source/program/aedifex/artifact/snapshot/version/value.lux6
-rw-r--r--stdlib/source/program/aedifex/artifact/type.lux2
-rw-r--r--stdlib/source/program/aedifex/cli.lux16
-rw-r--r--stdlib/source/program/aedifex/command/auto.lux2
-rw-r--r--stdlib/source/program/aedifex/command/build.lux18
-rw-r--r--stdlib/source/program/aedifex/dependency/deployment.lux6
-rw-r--r--stdlib/source/program/aedifex/dependency/resolution.lux16
-rw-r--r--stdlib/source/program/aedifex/hash.lux14
-rw-r--r--stdlib/source/program/aedifex/metadata.lux4
-rw-r--r--stdlib/source/program/aedifex/pom.lux6
-rw-r--r--stdlib/source/program/aedifex/profile.lux32
-rw-r--r--stdlib/source/program/aedifex/repository/local.lux4
-rw-r--r--stdlib/source/program/aedifex/runtime.lux2
-rw-r--r--stdlib/source/program/compositor.lux18
-rw-r--r--stdlib/source/program/compositor/export.lux2
-rw-r--r--stdlib/source/program/scriptum.lux8
18 files changed, 80 insertions, 80 deletions
diff --git a/stdlib/source/program/aedifex/artifact.lux b/stdlib/source/program/aedifex/artifact.lux
index ec955d4dd..a6980813e 100644
--- a/stdlib/source/program/aedifex/artifact.lux
+++ b/stdlib/source/program/aedifex/artifact.lux
@@ -95,7 +95,7 @@
(let [/ uri.separator
group (..directory / (get@ #group artifact))
name (get@ #name artifact)
- ## version (get@ #version artifact)
+ ... version (get@ #version artifact)
identity (..identity artifact)]
(%.format group / name / version / identity)))
diff --git a/stdlib/source/program/aedifex/artifact/extension.lux b/stdlib/source/program/aedifex/artifact/extension.lux
index 11a94bb7e..130dda74e 100644
--- a/stdlib/source/program/aedifex/artifact/extension.lux
+++ b/stdlib/source/program/aedifex/artifact/extension.lux
@@ -21,7 +21,7 @@
(def: .public type
(-> Extension //.Type)
- (text.replace_all ..separator ""))
+ (text.replaced ..separator ""))
(template [<name>]
[(def: .public <name>
diff --git a/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux b/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux
index 55ece62c7..63681a3fe 100644
--- a/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux
+++ b/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux
@@ -36,8 +36,8 @@
(#///.Remote stamp)
(let [(^slots [#///stamp.time #///stamp.build]) stamp]
- (%.format (text.replace_all ..snapshot
- (///time.format time)
- version)
+ (%.format (text.replaced ..snapshot
+ (///time.format time)
+ version)
..separator
(%.nat build)))))
diff --git a/stdlib/source/program/aedifex/artifact/type.lux b/stdlib/source/program/aedifex/artifact/type.lux
index dde76fc0c..ae6f9b79b 100644
--- a/stdlib/source/program/aedifex/artifact/type.lux
+++ b/stdlib/source/program/aedifex/artifact/type.lux
@@ -2,7 +2,7 @@
[library
[lux (#- Type)]])
-## https://maven.apache.org/ref/3.6.3/maven-core/artifact-handlers.html
+... https://maven.apache.org/ref/3.6.3/maven-core/artifact-handlers.html
(type: .public Type
Text)
diff --git a/stdlib/source/program/aedifex/cli.lux b/stdlib/source/program/aedifex/cli.lux
index 8e97e02d3..7f9fe61ff 100644
--- a/stdlib/source/program/aedifex/cli.lux
+++ b/stdlib/source/program/aedifex/cli.lux
@@ -48,24 +48,24 @@
(def: .public equivalence
(Equivalence Command)
($_ sum.equivalence
- ## #Version
+ ... #Version
..any_equivalence
- ## #Clean
+ ... #Clean
..any_equivalence
- ## #POM
+ ... #POM
..any_equivalence
- ## #Dependencies
+ ... #Dependencies
..any_equivalence
- ## #Install
+ ... #Install
..any_equivalence
- ## #Deploy
+ ... #Deploy
($_ product.equivalence
text.equivalence
text.equivalence
text.equivalence)
- ## #Compilation
+ ... #Compilation
..compilation_equivalence
- ## #Auto
+ ... #Auto
..compilation_equivalence))
(def: command'
diff --git a/stdlib/source/program/aedifex/command/auto.lux b/stdlib/source/program/aedifex/command/auto.lux
index 2c4c8ac19..579f68462 100644
--- a/stdlib/source/program/aedifex/command/auto.lux
+++ b/stdlib/source/program/aedifex/command/auto.lux
@@ -41,7 +41,7 @@
(def: (pause delay)
(-> Nat (Async (Try Any)))
- (async.delay delay (#try.Success [])))
+ (async.delayed delay (#try.Success [])))
(def: .public (do! delay watcher command)
(All [a]
diff --git a/stdlib/source/program/aedifex/command/build.lux b/stdlib/source/program/aedifex/command/build.lux
index ff7825678..00380e59b 100644
--- a/stdlib/source/program/aedifex/command/build.lux
+++ b/stdlib/source/program/aedifex/command/build.lux
@@ -115,7 +115,7 @@
artifact (get@ #///dependency.artifact dependency)]
(|> artifact
(///local.uri (get@ #///artifact.version artifact))
- (text.replace_all uri.separator /)
+ (text.replaced uri.separator /)
(format home /)
(text.suffix (format "." (get@ #///dependency.type dependency))))))
@@ -193,29 +193,29 @@
(template [<name> <capability>]
[(def: .public (<name> console process)
(-> (Console Async) (Process Async) (Async (Try Any)))
- ## This is a very odd way of implementing this function.
- ## But it's written this way because the more straightforward way (i.e. by using (try.with async.monad))
- ## eventually led to the function hanging/freezing.
- ## I'm not sure why it happened, but I got this weirder implementation to work.
+ ... This is a very odd way of implementing this function.
+ ... But it's written this way because the more straightforward way (i.e. by using (try.with async.monad))
+ ... eventually led to the function hanging/freezing.
+ ... I'm not sure why it happened, but I got this weirder implementation to work.
(let [[read! write!] (: [(Async (Try Any))
(async.Resolver (Try Any))]
(async.async []))
_ (|> (\ process <capability> [])
- (async.await (function (recur ?line)
+ (async.upon! (function (recur ?line)
(case ?line
(#try.Failure error)
(if (exception.match? shell.no_more_output error)
(write! (#try.Success []))
- (async.await write! (console.write_line error console)))
+ (async.upon! write! (console.write_line error console)))
(#try.Success line)
- (async.await (function (_ outcome)
+ (async.upon! (function (_ outcome)
(case outcome
(#try.Failure error)
(write! (#try.Failure error))
(#try.Success _)
- (async.await recur
+ (async.upon! recur
(\ process <capability> []))))
(console.write_line line console)))))
io.run)]
diff --git a/stdlib/source/program/aedifex/dependency/deployment.lux b/stdlib/source/program/aedifex/dependency/deployment.lux
index 6ff052a5a..d23e4a805 100644
--- a/stdlib/source/program/aedifex/dependency/deployment.lux
+++ b/stdlib/source/program/aedifex/dependency/deployment.lux
@@ -110,9 +110,9 @@
{#///artifact/snapshot/version/value.version version_template
#///artifact/snapshot/version/value.snapshot versioning_snapshot})
#///artifact/snapshot/version.updated now}))
- ## (set@ [#///metadata/snapshot.versioning #///artifact/versioning.snapshot]
- ## (list\compose (..artifacts type (product.right (get@ #///package.library package)))
- ## (..artifacts ///artifact/type.pom (product.right (get@ #///package.pom package)))))
+ ... (set@ [#///metadata/snapshot.versioning #///artifact/versioning.snapshot]
+ ... (list\compose (..artifacts type (product.right (get@ #///package.library package)))
+ ... (..artifacts ///artifact/type.pom (product.right (get@ #///package.pom package)))))
))))
(def: .public (one repository [artifact type] package)
diff --git a/stdlib/source/program/aedifex/dependency/resolution.lux b/stdlib/source/program/aedifex/dependency/resolution.lux
index c34d88494..ed4303ac5 100644
--- a/stdlib/source/program/aedifex/dependency/resolution.lux
+++ b/stdlib/source/program/aedifex/dependency/resolution.lux
@@ -214,7 +214,7 @@
(#.Item head tail)
(case (get@ [#//.artifact #///artifact.version] head)
- ## Skip if there is no version
+ ... Skip if there is no version
"" (recur repositories
successes
failures
@@ -234,13 +234,13 @@
///package.dependencies
(try\map set.list)
(try.else (list)))
- ## For security reasons, it's not a good idea to allow dependencies to introduce repositories.
- ## package_repositories (|> package
- ## ///package.repositories
- ## (try\map set.list)
- ## (try.else (list))
- ## (list\map new_repository))
- ## sub_repositories (list\compose repositories package_repositories)
+ ... For security reasons, it's not a good idea to allow dependencies to introduce repositories.
+ ... package_repositories (|> package
+ ... ///package.repositories
+ ... (try\map set.list)
+ ... (try.else (list))
+ ... (list\map new_repository))
+ ... sub_repositories (list\compose repositories package_repositories)
sub_repositories repositories]
[successes failures resolution] (recur sub_repositories
(#.Item head successes)
diff --git a/stdlib/source/program/aedifex/hash.lux b/stdlib/source/program/aedifex/hash.lux
index 95247c471..2e46286ea 100644
--- a/stdlib/source/program/aedifex/hash.lux
+++ b/stdlib/source/program/aedifex/hash.lux
@@ -21,9 +21,9 @@
[type
abstract]]])
-## TODO: Replace with pure-Lux implementations of these algorithms
-## https://en.wikipedia.org/wiki/SHA-1#SHA-1_pseudocode
-## https://en.wikipedia.org/wiki/MD5#Algorithm
+... TODO: Replace with pure-Lux implementations of these algorithms
+... https://en.wikipedia.org/wiki/SHA-1#SHA-1_pseudocode
+... https://en.wikipedia.org/wiki/MD5#Algorithm
(import: java/lang/String)
(import: java/security/MessageDigest
@@ -127,7 +127,7 @@
(#.Some [head tail])
(do try.monad
[head (\ n.hex decode head)
- output (binary.write/64 index head output)]
+ output (binary.write/64! index head output)]
(recur tail (inc chunk) output))
#.None
@@ -139,9 +139,9 @@
[head (\ n.hex decode input)
output (<write> index head output)]
(constructor output))])
- ([1 binary.write/8]
- [2 binary.write/16]
- [4 binary.write/32])
+ ([1 binary.write/8!]
+ [2 binary.write/16!]
+ [4 binary.write/32!])
_ (exception.except ..not_a_hash [(..encoding_size size) encoded])))))
(exception.except ..not_a_hash [(..encoding_size size) encoded]))))
diff --git a/stdlib/source/program/aedifex/metadata.lux b/stdlib/source/program/aedifex/metadata.lux
index 7b883e4f8..5badc4783 100644
--- a/stdlib/source/program/aedifex/metadata.lux
+++ b/stdlib/source/program/aedifex/metadata.lux
@@ -36,8 +36,8 @@
(def: .public (local_uri remote_uri)
(-> URI URI)
- (text.replace_once ..remote_file ..local_file remote_uri))
+ (text.replaced/1 ..remote_file ..local_file remote_uri))
(def: .public (remote_uri local_uri)
(-> URI URI)
- (text.replace_once ..local_file ..remote_file local_uri))
+ (text.replaced/1 ..local_file ..remote_file local_uri))
diff --git a/stdlib/source/program/aedifex/pom.lux b/stdlib/source/program/aedifex/pom.lux
index 13900d276..e2ad11079 100644
--- a/stdlib/source/program/aedifex/pom.lux
+++ b/stdlib/source/program/aedifex/pom.lux
@@ -29,7 +29,7 @@
["#." artifact (#+ Artifact)
["#/." type]]])
-## https://maven.apache.org/pom.html
+... https://maven.apache.org/pom.html
(def: project_tag "project")
(def: dependency_tag "dependency")
@@ -178,8 +178,8 @@
#//artifact.version (|> properties
(dictionary.get ["" ..version_tag])
(maybe.else "")
- (text.replace_all "${project.version}" own_version)
- (text.replace_all "${project.parent.version}" parent_version))}
+ (text.replaced "${project.version}" own_version)
+ (text.replaced "${project.parent.version}" parent_version))}
#//dependency.type (|> properties
(dictionary.get ["" "type"])
(maybe.else //artifact/type.jvm_library))})))))
diff --git a/stdlib/source/program/aedifex/profile.lux b/stdlib/source/program/aedifex/profile.lux
index 93eeec473..ffd549c06 100644
--- a/stdlib/source/program/aedifex/profile.lux
+++ b/stdlib/source/program/aedifex/profile.lux
@@ -174,37 +174,37 @@
(def: .public equivalence
(Equivalence Profile)
($_ product.equivalence
- ## #parents
+ ... #parents
(list.equivalence text.equivalence)
- ## #identity
+ ... #identity
(maybe.equivalence artifact.equivalence)
- ## #info
+ ... #info
(maybe.equivalence ..info_equivalence)
- ## #repositories
+ ... #repositories
set.equivalence
- ## #dependencies
+ ... #dependencies
set.equivalence
- ## #compiler
+ ... #compiler
dependency.equivalence
- ## #sources
+ ... #sources
set.equivalence
- ## #target
+ ... #target
text.equivalence
- ## #program
+ ... #program
(maybe.equivalence text.equivalence)
- ## #test
+ ... #test
(maybe.equivalence text.equivalence)
- ## #deploy_repositories
+ ... #deploy_repositories
(dictionary.equivalence text.equivalence)
- ## #java
+ ... #java
runtime.equivalence
- ## #js
+ ... #js
runtime.equivalence
- ## #python
+ ... #python
runtime.equivalence
- ## #lua
+ ... #lua
runtime.equivalence
- ## #ruby
+ ... #ruby
runtime.equivalence))
(implementation: .public monoid
diff --git a/stdlib/source/program/aedifex/repository/local.lux b/stdlib/source/program/aedifex/repository/local.lux
index f59a04b85..907610233 100644
--- a/stdlib/source/program/aedifex/repository/local.lux
+++ b/stdlib/source/program/aedifex/repository/local.lux
@@ -23,12 +23,12 @@
(def: (root program /)
(-> (Program Async) Text file.Path)
(|> ///local.repository
- (text.replace_all uri.separator /)
+ (text.replaced uri.separator /)
(format (\ program home) /)))
(def: (path /)
(-> Text (-> URI file.Path))
- (text.replace_all uri.separator /))
+ (text.replaced uri.separator /))
(def: (absolute_path program /)
(-> (Program Async) Text (-> URI file.Path))
diff --git a/stdlib/source/program/aedifex/runtime.lux b/stdlib/source/program/aedifex/runtime.lux
index 842708e44..b239d03ea 100644
--- a/stdlib/source/program/aedifex/runtime.lux
+++ b/stdlib/source/program/aedifex/runtime.lux
@@ -34,7 +34,7 @@
[default_js "node" ["--stack_size=8192"]]
[default_python "python3" []]
[default_lua "lua" []]
- ## [default_ruby "RUBY_THREAD_VM_STACK_SIZE=15700000 ruby" []]
+ ... [default_ruby "RUBY_THREAD_VM_STACK_SIZE=15700000 ruby" []]
[default_ruby "ruby" []]
)
diff --git a/stdlib/source/program/compositor.lux b/stdlib/source/program/compositor.lux
index 88ceec96c..f19575859 100644
--- a/stdlib/source/program/compositor.lux
+++ b/stdlib/source/program/compositor.lux
@@ -24,7 +24,7 @@
["." world #_
["." file]
["#/." program]
- ## ["." console]
+ ... ["." console]
]
[tool
[compiler
@@ -49,7 +49,7 @@
["." dependency]]
[io
["ioW" archive]]]]
- ## ["." interpreter]
+ ... ["." interpreter]
]]]
["." / #_
["#." cli (#+ Service)]
@@ -172,12 +172,12 @@
(in (debug.log! "Export complete!"))))
(#/cli.Interpretation interpretation)
- ## TODO: Fix the interpreter...
+ ... TODO: Fix the interpreter...
(undefined)
- ## (<| (or_crash! "Interpretation failed:")
- ## (do {! async.monad}
- ## [console (|> console.default
- ## async.future
- ## (\ ! map (|>> try.assumed console.async)))]
- ## (interpreter.run (try.with async.monad) console platform interpretation generation_bundle)))
+ ... (<| (or_crash! "Interpretation failed:")
+ ... (do {! async.monad}
+ ... [console (|> console.default
+ ... async.future
+ ... (\ ! map (|>> try.assumed console.async)))]
+ ... (interpreter.run (try.with async.monad) console platform interpretation generation_bundle)))
))))
diff --git a/stdlib/source/program/compositor/export.lux b/stdlib/source/program/compositor/export.lux
index ade242f57..b229b36ba 100644
--- a/stdlib/source/program/compositor/export.lux
+++ b/stdlib/source/program/compositor/export.lux
@@ -48,7 +48,7 @@
(function (_ [path source_code])
(do try.monad
[path (|> path
- (text.replace_all (\ fs separator) .module_separator)
+ (text.replaced (\ fs separator) .module_separator)
tar.path)
source_code (tar.content source_code)]
(in (#tar.Normal [path
diff --git a/stdlib/source/program/scriptum.lux b/stdlib/source/program/scriptum.lux
index c9b27a305..b18ce7bff 100644
--- a/stdlib/source/program/scriptum.lux
+++ b/stdlib/source/program/scriptum.lux
@@ -32,8 +32,8 @@
["." annotation]]
[world
["." file]]]]
- ## This was added to make sure that all tested modules are picked up
- ## and their documentation is generated.
+ ... This was added to make sure that all tested modules are picked up
+ ... and their documentation is generated.
[test/lux (#+)])
(def: name_options "abcdefghijklmnopqrstuvwxyz")
@@ -300,7 +300,7 @@
(|>> (#.Item [name def_annotations def_type])))
organization)
- ## else
+ ... else
(update@ #values
(: (Mutation (List Value))
(|>> (#.Item [name def_annotations def_type])))
@@ -491,7 +491,7 @@
(def: (save_documentation! [module_name documentation])
(-> [Text (Markdown Block)] (IO Any))
- (let [path (format (text.replace_all "/" "_" module_name) ".md")]
+ (let [path (format (text.replaced "/" "_" module_name) ".md")]
(do io.monad
[outcome (\ file.default write (\ utf8.codec encode (md.markdown documentation)) path)]
(in (case outcome