Commit f4c599d2 authored by simonpj's avatar simonpj
Browse files

[project @ 2001-03-01 17:06:53 by simonpj]

Add comment
parent 86db5bf5
......@@ -762,6 +762,8 @@ in error messages.
unQualInScope :: GlobalRdrEnv -> Name -> Bool
-- True if 'f' is in scope, and has only one binding
-- (i.e. false if A.f and B.f are both in scope as unqualified 'f')
unQualInScope env
= (`elemNameSet` unqual_names)
......@@ -198,6 +198,9 @@ importsFromLocalDecls this_mod decls
(_, dups) = removeDups compare all_names
-- Check for duplicate definitions
-- The complaint will come out as "Multiple declarations of Foo.f" because
-- since 'f' is in the env twice, the unQualInScope used by the error-msg
-- printer returns False. It seems awkward to fix, unfortunately.
mapRn_ (addErrRn . dupDeclErr) dups `thenRn_`
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment