From d3fea3aad3d02e0de26ff941aad0b6f11526624b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Pasteur?= Date: Tue, 27 Jul 2010 09:29:20 +0200 Subject: [PATCH] Added test for alias types --- test/good/type_alias.ept | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 test/good/type_alias.ept diff --git a/test/good/type_alias.ept b/test/good/type_alias.ept new file mode 100644 index 0000000..013013f --- /dev/null +++ b/test/good/type_alias.ept @@ -0,0 +1,22 @@ +const n:int = 10 + +type metres = int +type tableau = int^n +type matrice = metres^n^n + +fun f(a:metres) returns (o: metres) +let + o = a + 1; +tel + +fun g(a:tableau) returns (o:tableau) +let + o = map f <>(a); +tel + +fun h(a:matrice) returns (o:matrice) +var x : matrice; +let + x = a; + o = map g <>(x); +tel \ No newline at end of file