blob: 06ea7c324bd82348ac662b83f520bd251b10abfa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
(;module:
lux
(lux (control [monad #+ do])
(data [text]
text/format
(coll ["D" dict])
[maybe]))
(luxc ["&" base]
(lang ["la" analysis #+ Analysis]))
(. ["&&;" common]))
(def: #export (analyse-procedure analyse proc-name proc-args)
(-> &;Analyser Text (List Code) (Lux Analysis))
(default (&;fail (format "Unknown procedure: " (%t proc-name)))
(do maybe;Monad<Maybe>
[proc (D;get proc-name &&common;procedures)]
(wrap (proc analyse proc-args)))))
|