]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.scl.compiler/tests/org/simantics/scl/compiler/tests/scl/ClashingInstance.scl
Migrated source code from Simantics SVN
[simantics/platform.git] / bundles / org.simantics.scl.compiler / tests / org / simantics / scl / compiler / tests / scl / ClashingInstance.scl
diff --git a/bundles/org.simantics.scl.compiler/tests/org/simantics/scl/compiler/tests/scl/ClashingInstance.scl b/bundles/org.simantics.scl.compiler/tests/org/simantics/scl/compiler/tests/scl/ClashingInstance.scl
new file mode 100644 (file)
index 0000000..72178db
--- /dev/null
@@ -0,0 +1,14 @@
+import "JavaBuiltin" as Java\r
+\r
+infixl 6 (+)\r
+\r
+class Additive a where \r
+    (+)  :: a -> a -> a    \r
+    \r
+instance Additive Double where\r
+    (+) = Java.dadd\r
+\r
+instance Additive Double where\r
+    (+) = Java.dadd\r
+--\r
+11:1-12:20: Duplicate definition of the instance Additive Double.
\ No newline at end of file