TYPE E = e1:INT e2:STR e3:SYM; ; EE = INT * STR; F = v1:SYM; A = INT | STR | SYM; ENDTYPE x0 <- E(12,"batatas",'tomates); x1 <- in-E( <12,"batatas",'tomates>); x2 <- out-E(x0); _ok("in_ and out_", in-E( out-E( x0) ) , x0 ); _ok("curry tup2arg",curry(tup2arg)(E)(<12,"batatas",'tomates>), x0 ); y0 <- F('a8); _ok("tup with one field", in-F( out-F( y0) ), y0); x1 <- in-A( i1(12)); _ok("union", in-A( out-A( x1) ), x1); TYPE Point = XX:INT YY:INT; CPoint = Lb1:STR P:Point; Transf = Lb2:STR Q:Point T: (INT --> INT); ENDTYPE ;test ; comp <- _comp; ; id(x) = x; succ(x) = x .+ 1; pp0 <- Point(0,0); pp1 <- Point(5,10); cc1 <- CPoint("relative origin",pp1); tt0 <- Transf("origin",pp0, lambda(x) . (x .* x) .+ 7); tt1 <- Transf("origin",pp1, succ); out-Point(pp0); _ok("type _x_ in-type", (id _x_ out-Point) (out-CPoint(cc1)), <"relative origin",<5,10>> );