Vag Vagoff wrote:
On 13.04.2011 4:13, Adam Chlipala wrote:
This behavior is just as in ML or Haskell. You are shadowing a definition, but the old definition doesn't "go away," it just becomes impossible to reference. At the end of the file, [y] has a type that refers to an out-of-scope identifier, but that isn't problematic semantically.

No, in Haskell you can shadow only by local (let or where) definitions, not top level.
There is,
- toplevel definition in current module clashes with any imported definitions (there is why "hiding" is used) - toplevel definition in current module clashes with other toplevel definitions in current module

Ah, thanks for the correction. I should stop making claims about Haskell without doing some programming in it first. ;)

_______________________________________________
Ur mailing list
[email protected]
http://www.impredicative.com/cgi-bin/mailman/listinfo/ur

Reply via email to