view tests/functor.lac @ 40:e3d3c2791105

Functor parsing
author Adam Chlipala <adamc@hcoop.net>
date Thu, 19 Jun 2008 15:15:00 -0400
parents
children 1405d8c26790
line wrap: on
line source
signature S = sig
        type t
        val z : t
        val s : t -> t
end

signature T = sig
        type t
        val three : t
end

structure F = functor (M : S) : T => struct
        val t = M.t
        val three = M.s (M.s (M.s M.z))
end