diff options
author | Eduardo Julian | 2019-03-12 23:24:41 -0400 |
---|---|---|
committer | Eduardo Julian | 2019-03-12 23:24:41 -0400 |
commit | fafed063904d6ca7bfa3d9c4ba4b8d44e7b97549 (patch) | |
tree | 3b8408bbdb29a0ffa8e60e2b92ac893937ea9cdb /stdlib | |
parent | 62cfd42fad011880491c937e3cb33c19febd3af4 (diff) |
Re-named ":extract" to ":by-example".
Diffstat (limited to 'stdlib')
-rw-r--r-- | stdlib/source/lux/tool/compiler/default/platform.lux | 2 | ||||
-rw-r--r-- | stdlib/source/lux/tool/compiler/phase/extension/statement.lux | 10 | ||||
-rw-r--r-- | stdlib/source/lux/type.lux | 6 | ||||
-rw-r--r-- | stdlib/source/test/lux/type.lux | 6 |
4 files changed, 12 insertions, 12 deletions
diff --git a/stdlib/source/lux/tool/compiler/default/platform.lux b/stdlib/source/lux/tool/compiler/default/platform.lux index ced79a306..73b5d8764 100644 --- a/stdlib/source/lux/tool/compiler/default/platform.lux +++ b/stdlib/source/lux/tool/compiler/default/platform.lux @@ -1,6 +1,6 @@ (.module: [lux (#- Module) - [type (#+ :share :extract)] + [type (#+ :share)] [control ["." monad (#+ Monad do)]] [data diff --git a/stdlib/source/lux/tool/compiler/phase/extension/statement.lux b/stdlib/source/lux/tool/compiler/phase/extension/statement.lux index 749924650..4f5bdb922 100644 --- a/stdlib/source/lux/tool/compiler/phase/extension/statement.lux +++ b/stdlib/source/lux/tool/compiler/phase/extension/statement.lux @@ -10,7 +10,7 @@ ["." list ("#/." functor)] ["." dictionary]]] ["." macro] - [type (#+ :share :extract) + [type (#+ :share :by-example) ["." check]]] ["." // ["." bundle] @@ -183,10 +183,10 @@ (case inputsC+ (^ (list [_ (#.Text name)] valueC)) (do ///.monad - [[_ handlerT handlerV] (evaluate! (:extract [anchor expression statement] - {(Handler anchor expression statement) - handler} - <type>) + [[_ handlerT handlerV] (evaluate! (:by-example [anchor expression statement] + {(Handler anchor expression statement) + handler} + <type>) valueC)] (<| <scope> (//.install name) diff --git a/stdlib/source/lux/type.lux b/stdlib/source/lux/type.lux index a760180c5..f18544494 100644 --- a/stdlib/source/lux/type.lux +++ b/stdlib/source/lux/type.lux @@ -391,9 +391,9 @@ (:assume (~ (get@ #expression computation))))))] (wrap (list (` ((~ shareC) (~ (get@ #expression exemplar))))))))) -(syntax: #export (:extract {type-vars type-parameters} - {exemplar typed} - {extraction s.any}) +(syntax: #export (:by-example {type-vars type-parameters} + {exemplar typed} + {extraction s.any}) (wrap (list (` (:of (:share [(~+ (list/map code.local-identifier type-vars))] {(~ (get@ #type exemplar)) (~ (get@ #expression exemplar))} diff --git a/stdlib/source/test/lux/type.lux b/stdlib/source/test/lux/type.lux index c7daced97..b9a6f09e4 100644 --- a/stdlib/source/test/lux/type.lux +++ b/stdlib/source/test/lux/type.lux @@ -173,6 +173,6 @@ (let [example (: (Maybe Nat) #.Nonae)] (type/= (type (List Nat)) - (:extract [a] - {(Maybe a) example} - (List a)))))) + (:by-example [a] + {(Maybe a) example} + (List a)))))) |