more work on case
This commit is contained in:
@@ -9,6 +9,7 @@ import Data.List
|
||||
import Lib.Types -- Name / Tm
|
||||
import Lib.TopContext
|
||||
import Lib.TT -- lookupMeta
|
||||
import Lib.Util
|
||||
|
||||
public export
|
||||
data CExp : Type
|
||||
@@ -31,13 +32,6 @@ data CExp : Type where
|
||||
CRef : Name -> CExp
|
||||
CMeta : Nat -> CExp
|
||||
|
||||
funArgs : Tm -> (Tm, List Tm)
|
||||
funArgs tm = go tm []
|
||||
where
|
||||
go : Tm -> List Tm -> (Tm, List Tm)
|
||||
go (App _ t u) args = go t (u :: args)
|
||||
go t args = (t, args)
|
||||
|
||||
||| I'm counting Lam in the term for arity. This matches what I need in
|
||||
||| code gen.
|
||||
export
|
||||
|
||||
Reference in New Issue
Block a user