comparison tests/functor.lac @ 42:b3fbbc6cb1e5

Elaborating 'where'
author Adam Chlipala <adamc@hcoop.net>
date Thu, 19 Jun 2008 16:35:40 -0400
parents 1405d8c26790
children d94c484337d0
comparison
equal deleted inserted replaced
41:1405d8c26790 42:b3fbbc6cb1e5
7 signature T = sig 7 signature T = sig
8 type t 8 type t
9 val three : t 9 val three : t
10 end 10 end
11 11
12 signature F = functor (M : S) : T 12 functor F (M : S) : T where type t = M.t = struct
13
14 structure F = functor (M : S) : T => struct
15 type t = M.t 13 type t = M.t
16 val three = M.s (M.s (M.s M.z)) 14 val three = M.s (M.s (M.s M.z))
17 end 15 end
18
19 structure F2 : F = F