我经常读到我不应该在Haskell中混合制表符和空格,或者我根本不应该使用制表符.为什么?
我使用的是 Leksah IDE 0.15.0.1,在编译示例包时收到警告:“名称...在源文件中找到,但不在范围内”。
此警告的含义是什么?
我用谷歌搜索了这篇文章,但发现有启发性。

我正在尝试加载以下程序
gcd a b = if b == 0
then a
else gcd b (rem a b)
Run Code Online (Sandbox Code Playgroud)
但是我得到了错误
Prelude> :l euclidean.hs
[1 of 1] Compiling Main ( euclidean.hs, interpreted )
euclidean.hs:3:8:
Ambiguous occurrence `gcd'
It could refer to either `Main.gcd', defined at euclidean.hs:1:0
or `Prelude.gcd', imported from Prelude
Failed, modules loaded: none.
Run Code Online (Sandbox Code Playgroud)
我从改变函数名gcd来main和我
Couldn't match expected type `IO t'
against inferred type `a -> a -> a'
In the expression: main
When checking the type of …Run Code Online (Sandbox Code Playgroud)