<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
</head>
<body bgcolor="#ffffff" text="#000000">
<div class="moz-text-flowed"
 style="font-family: -moz-fixed; font-size: 12px;" lang="x-western">Hello,
<br>
<br>
I find clm (on Linux) complains:
<br>
<br>
&nbsp; "Error [Eq.icl,4,import]: == multiply defined"
<br>
<br>
if StdString is imported in the following program:
<br>
<br>
--- file Eq.icl ---
<br>
module Eq
<br>
<br>
import StdClass, StdList, StdArray
<br>
import StdString&nbsp; // must comment this line to avoid conflict with
instance == {#Real} below
<br>
<br>
instance == {#Real}
<br>
where
<br>
&nbsp; (==) infix 2:: !{#Real} !{#Real} -&gt; Bool
<br>
&nbsp; (==) v1 v2 = and [e1 == e2 \\ e1 &lt;-: v1 &amp; e2 &lt;-: v2]
<br>
<br>
Start :: Bool
<br>
Start = v1 == v1
<br>
where
<br>
&nbsp; v1 :: {#Real}
<br>
&nbsp; v1 = {1.0,2.0,3.0}
<br>
&nbsp; v2 :: {#Real}
<br>
&nbsp; v2 = {1.0,2.0,3.0}
<br>
---
<br>
Apparently, StdString's instance == {#Char} conflicts with instance ==
{#Real}.&nbsp; Why should these instance declarations clash?&nbsp; How may I
import StdString, yet still define == instance for arrays?
<br>
<br>
- David
<br>
<br>
<br>
</div>
</body>
</html>