]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/InstanceIsTypoedAsClass.scl
Automatic execution of SCL tests in Maven
[simantics/platform.git] / tests / org.simantics.scl.compiler.tests / src / org / simantics / scl / compiler / tests / scl / InstanceIsTypoedAsClass.scl
diff --git a/tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/InstanceIsTypoedAsClass.scl b/tests/org.simantics.scl.compiler.tests/src/org/simantics/scl/compiler/tests/scl/InstanceIsTypoedAsClass.scl
new file mode 100644 (file)
index 0000000..f3973cc
--- /dev/null
@@ -0,0 +1,9 @@
+class Functor f where\r
+    map :: (a -> b) -> f a -> f b\r
+    \r
+data Foo a = Foo a\r
+\r
+class Functor Foo where\r
+    map f (Foo x) = Foo (f x)\r
+--\r
+6:1-7:30: Class Functor has already been defined in this module.
\ No newline at end of file