diff options
author | Eduardo Julian | 2014-12-15 00:56:48 -0400 |
---|---|---|
committer | Eduardo Julian | 2014-12-15 00:56:48 -0400 |
commit | 5883c0d11c21a74ba493ea369ff01d7baed80a41 (patch) | |
tree | 390a7062ad4d96b5000e422723d23c8d591b24fe /src/lang/analyser.clj | |
parent | 604e1d0c108f6153b599684b4b7828eae709118a (diff) |
Added tuples.
Diffstat (limited to 'src/lang/analyser.clj')
-rw-r--r-- | src/lang/analyser.clj | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lang/analyser.clj b/src/lang/analyser.clj index 115204570..122d6353d 100644 --- a/src/lang/analyser.clj +++ b/src/lang/analyser.clj @@ -96,6 +96,11 @@ (exec [=value (analyse-form* ?value)] (return (annotated [::variant ?tag =value] [::&type/variant ?tag (:type =value)])))) +(defanalyser analyse-tuple + [::&parser/tuple ?elems] + (exec [=elems (map-m analyse-form* ?elems)] + (return (annotated [::tuple =elems] [::&type/tuple (mapv :type =elems)])))) + (defanalyser analyse-ident [::&parser/ident ?ident] (resolve ?ident)) @@ -211,6 +216,7 @@ (try-all-m [analyse-boolean analyse-string analyse-variant + analyse-tuple analyse-ident analyse-ann-class analyse-static-access |