aboutsummaryrefslogtreecommitdiff
path: root/new-luxc/test/test/luxc/common.lux
blob: 6892274e405334131cbd1e76acc441f5c9957c4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
(;module:
  lux
  (lux (control pipe)
       ["r" math/random "r/" Monad<Random>]
       (data ["R" result])
       [macro]
       (macro [code]))
  (luxc ["&" base]
        [analyser]
        ["&;" host]))

(def: init-compiler-info
  Compiler-Info
  {#;compiler-version &;compiler-version
   #;compiler-mode    #;Build})

(def: init-type-context
  Type-Context
  {#;ex-counter +0
   #;var-counter +0
   #;var-bindings (list)})

(def: #export (init-compiler _)
  (-> Top Compiler)
  {#;info            init-compiler-info
   #;source          [dummy-cursor ""]
   #;cursor          dummy-cursor
   #;modules         (list)
   #;scopes          (list)
   #;type-context    init-type-context
   #;expected        #;None
   #;seed            +0
   #;scope-type-vars (list)
   #;host            (:! Void (&host;init-host []))})