Help wanted with hugs error message
I am compiling the following inoffensive source file, dubbed finterp.lhs: '''Interpreter for factors'''
module FactorInterp where import Ast (Sym) import Value () import Factor
result = "*"
exp (Sym s) = Vee [result `eq` Value.Sym s :@: 1.0]
Hugs reports: ERROR "finterp.lhs" (line 10): Definition of variable "exp" clashes with import But there is no explicit `exp' in any of my other modules: : nr@labrador 1337 ; grep -w exp *.lhs finterp.lhs:> exp (Sym s) = Vee [result `eq` Value.Sym s :@: 1.0] Can anyone help me to find an expunge this error? Thanks, Norman
[snip]
Hugs reports:
ERROR "finterp.lhs" (line 10): Definition of variable "exp" clashes with import
But there is no explicit `exp' in any of my other modules:
: nr@labrador 1337 ; grep -w exp *.lhs finterp.lhs:> exp (Sym s) = Vee [result `eq` Value.Sym s :@: 1.0]
Can anyone help me to find an expunge this error?
[snip] "exp" is defined as exponentiation, as part of the "Floating" type class in the standard Prelude - which is imported by default. -Rob
Fri, 04 May 2001 20:06:23 +0100, Robert Ennals <Robert.Ennals@cl.cam.ac.uk> pisze:
"exp" is defined as exponentiation, as part of the "Floating" type class in the standard Prelude - which is imported by default.
And to fix the problem you may do either of these: * import Prelude hiding (exp) * Use FactorInterp.exp everywhere except the definition. * Choose a different name. -- __("< Marcin Kowalczyk * qrczak@knm.org.pl http://qrczak.ids.net.pl/ \__/ ^^ SYGNATURA ZASTÊPCZA QRCZAK
participants (3)
-
Marcin 'Qrczak' Kowalczyk -
Norman Ramsey -
Robert Ennals