Skip to content

Commit

Permalink
compiler: make a file for au-ts#29; turn au-ts#22-6 to pass
Browse files Browse the repository at this point in the history
  • Loading branch information
Zilin Chen authored and ajaysusarla committed Nov 22, 2016
1 parent 0f6ff35 commit a4e40a4
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
File renamed without changes.
24 changes: 24 additions & 0 deletions cogent/tests/pass_ticket-e29.cogent
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
type ExState
type VfsInode
type OSBuffer

type LRR acc brk = (acc, <Iterate|Break brk>)

seq32: all (acc,obsv,rbrk). Seq32Param acc obsv rbrk -> LRR acc rbrk
type Seq32Param acc obsv rbrk = #{
f: Seq32_body acc obsv rbrk,
acc: acc,
obsv: obsv!
}
type Seq32_body acc obsv rbrk = #{acc:acc, obsv:obsv!} -> LRR acc rbrk

bar: Seq32_body OSBuffer () ()

foo : (OSBuffer, VfsInode) -> (OSBuffer, VfsInode)
foo (buf, inode) =
let (buf, _) = seq32 #{
f = bar,
acc = buf,
obsv = () }
in (buf, inode)

0 comments on commit a4e40a4

Please sign in to comment.