Import Debian changes 20180207-1
[hcoop/debian/mlton.git] / mlton / elaborate / decs.fun
1 (* Copyright (C) 1999-2005 Henry Cejtin, Matthew Fluet, Suresh
2 * Jagannathan, and Stephen Weeks.
3 * Copyright (C) 1997-2000 NEC Research Institute.
4 *
5 * MLton is released under a BSD-style license.
6 * See the file MLton-LICENSE for details.
7 *)
8
9 functor Decs (S: DECS_STRUCTS): DECS =
10 struct
11
12 open S
13
14 structure Dec = CoreML.Dec
15
16 type dec = CoreML.Dec.t
17
18 open AppendList
19
20 type t = dec t
21
22 fun add (ds, d) = append (ds, single d)
23
24 fun layout ds =
25 let
26 open Layout
27 in
28 align (Vector.toListMap (toVector ds, Dec.layout))
29 end
30
31 end