aboutsummaryrefslogtreecommitdiff
path: root/new-luxc/test
diff options
context:
space:
mode:
authorEduardo Julian2017-05-20 15:39:29 -0400
committerEduardo Julian2017-05-20 15:39:29 -0400
commit76d209d7b33f713259bd9ddb453d571f814005c9 (patch)
tree831b34bbb951695a2df5af758721d119f1ffc08a /new-luxc/test
parentb81f241bd90092f52a47f64f4dc8297cc4f82f56 (diff)
- Some refactoring.
Diffstat (limited to '')
-rw-r--r--new-luxc/test/test/luxc/analyser/primitive.lux10
1 files changed, 9 insertions, 1 deletions
diff --git a/new-luxc/test/test/luxc/analyser/primitive.lux b/new-luxc/test/test/luxc/analyser/primitive.lux
index 6053e2fd7..e844c194d 100644
--- a/new-luxc/test/test/luxc/analyser/primitive.lux
+++ b/new-luxc/test/test/luxc/analyser/primitive.lux
@@ -48,7 +48,6 @@
false))
)]
- ["unit" Unit #~;Unit [] (function [value] @;analyse-unit)]
["bool" Bool #~;Bool %bool% @;analyse-bool]
["nat" Nat #~;Nat %nat% @;analyse-nat]
["int" Int #~;Int %int% @;analyse-int]
@@ -58,4 +57,13 @@
["text" Text #~;Text %text% @;analyse-text]
)]
($_ seq
+ (assert (format "Can analyse unit.")
+ (|> (@common;with-unknown-type
+ @;analyse-unit)
+ (macro;run init-compiler)
+ (case> (^ (#R;Success [_type (#~;Tuple (list))]))
+ (Type/= Unit _type)
+
+ _
+ false)))
<primitives>)))