diff options
author | Eduardo Julian | 2017-10-31 22:26:13 -0400 |
---|---|---|
committer | Eduardo Julian | 2017-10-31 22:26:13 -0400 |
commit | 19c589edc2c1dd77550e26d4f5cf78ec772da337 (patch) | |
tree | d070c773c7bd5cec8d33caa1841fbe0e342ec563 /new-luxc/source/luxc/synthesizer/structure.lux | |
parent | 6c753288a89eadb3f7d70a8844e466c48c809051 (diff) |
- Migrated the format of analysis nodes from a custom data-type, to just Code nodes.
Diffstat (limited to '')
-rw-r--r-- | new-luxc/source/luxc/synthesizer/structure.lux | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/new-luxc/source/luxc/synthesizer/structure.lux b/new-luxc/source/luxc/synthesizer/structure.lux deleted file mode 100644 index 403817c53..000000000 --- a/new-luxc/source/luxc/synthesizer/structure.lux +++ /dev/null @@ -1,28 +0,0 @@ -(;module: - lux - (luxc (lang ["la" analysis]))) - -(def: #export (unfold-tuple tuple) - (-> la;Analysis (List la;Analysis)) - (case tuple - (#la;Product left right) - (#;Cons left (unfold-tuple right)) - - _ - (list tuple))) - -(def: #export (unfold-variant variant) - (-> (Either la;Analysis la;Analysis) [Nat Bool la;Analysis]) - (loop [so-far +0 - variantA variant] - (case variantA - (#;Left valueA) - (case valueA - (#la;Sum choice) - (recur (n.inc so-far) choice) - - _ - [so-far false valueA]) - - (#;Right valueA) - [(n.inc so-far) true valueA]))) |