1signature NODE_LIST_DIM = 2sig 3 (* Versions of width, height, and depth for node lists *) 4 val hlistWidth: BoxTypes.hlist -> BasicTypes.dist 5 val hlistHeight: BoxTypes.hlist -> BasicTypes.dist 6 val hlistDepth: BoxTypes.hlist -> BasicTypes.dist 7 val vlistVsize: BoxTypes.vlist -> BasicTypes.dist 8 val vlistWidth: BoxTypes.vlist -> BasicTypes.dist 9end (* signature NODE_LIST_DIM *) 10(*----------*) 11 12structure NodeListDim: NODE_LIST_DIM = 13struct 14 open General 15 open NodeDim 16 fun compute f g nl = f (map g nl) 17 val hlistWidth = compute sum width 18 val hlistHeight = compute Max height 19 val hlistDepth = compute Max depth 20 val vlistWidth = compute Max vwidth 21 val vlistVsize = compute sum vsize 22end (* structure NodeListDim *) 23