aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source
diff options
context:
space:
mode:
authorEduardo Julian2017-01-28 22:21:58 -0400
committerEduardo Julian2017-01-28 22:21:58 -0400
commit0765ddaa5dfebba732c06ac563df0e55d08fc6fc (patch)
tree7f4aa917b2ea23f8daced94f2ec8133f65ce9193 /stdlib/source
parent9e87e07dc32e2c8acc5d95d2e56babded93fc7ac (diff)
- Some refactorings.
Diffstat (limited to 'stdlib/source')
-rw-r--r--stdlib/source/lux/data/text/format.lux2
-rw-r--r--stdlib/source/lux/math/logic/continuous.lux26
2 files changed, 14 insertions, 14 deletions
diff --git a/stdlib/source/lux/data/text/format.lux b/stdlib/source/lux/data/text/format.lux
index 69928366d..153ef4fe3 100644
--- a/stdlib/source/lux/data/text/format.lux
+++ b/stdlib/source/lux/data/text/format.lux
@@ -35,7 +35,7 @@
[%b Bool (:: bool;Codec<Text,Bool> encode)]
[%n Nat (:: number;Codec<Text,Nat> encode)]
[%i Int (:: number;Codec<Text,Int> encode)]
- [%f Deg (:: number;Codec<Text,Deg> encode)]
+ [%d Deg (:: number;Codec<Text,Deg> encode)]
[%r Real (:: number;Codec<Text,Real> encode)]
[%c Char (:: char;Codec<Text,Char> encode)]
[%t Text (:: text;Codec<Text,Text> encode)]
diff --git a/stdlib/source/lux/math/logic/continuous.lux b/stdlib/source/lux/math/logic/continuous.lux
index c81f5e526..0546cb46c 100644
--- a/stdlib/source/lux/math/logic/continuous.lux
+++ b/stdlib/source/lux/math/logic/continuous.lux
@@ -2,38 +2,38 @@
lux
(lux (data [number "Deg/" Interval<Deg>])))
-(def: #export TRUE Deg Deg/top)
-(def: #export FALSE Deg Deg/bottom)
+(def: #export ~true Deg Deg/top)
+(def: #export ~false Deg Deg/bottom)
(do-template [<name> <chooser>]
[(def: #export <name>
(-> Deg Deg Deg)
<chooser>)]
- [and~ d.min]
- [or~ d.max]
+ [~and d.min]
+ [~or d.max]
)
-(def: #export (not~ input)
+(def: #export (~not input)
(-> Deg Deg)
- (d.- input TRUE))
+ (d.- input ~true))
-(def: #export (implies~ consequent antecedent)
+(def: #export (~implies consequent antecedent)
(-> Deg Deg Deg)
- (or~ (not~ antecedent)
+ (~or (~not antecedent)
consequent))
(def: #export (includes~ sub super)
(-> Deg Deg Deg)
- (let [-sub (not~ sub)
+ (let [-sub (~not sub)
sum (d.+ -sub super)
no-overflow? (and (d.>= -sub sum)
(d.>= super sum))]
(if no-overflow?
sum
- TRUE)))
+ ~true)))
-(def: #export (=~ left right)
+(def: #export (~= left right)
(-> Deg Deg Deg)
- (and~ (or~ (not~ left) right)
- (or~ left (not~ right))))
+ (~and (~or (~not left) right)
+ (~or left (~not right))))