Skip to content
Snippets Groups Projects
Commit d43f6852 authored by sof's avatar sof
Browse files

[project @ 1998-03-03 18:57:49 by sof]

addAvailEnv: special handling of explicit exports of class methods.
parent 4a0aef4a
No related merge requests found
......@@ -412,11 +412,17 @@ addAvailEnv :: Bool -> RdrNameIE -> AvailEnv -> AvailInfo -> RnM s d AvailEnv
addAvailEnv warn_dups ie env NotAvailable = returnRn env
addAvailEnv warn_dups ie env (AvailTC _ []) = returnRn env
addAvailEnv warn_dups ie env avail
| warn_dups = mapMaybeRn (addErrRn . availClashErr) () conflict `thenRn_`
| warn_dups = mapMaybeRn (addErrRn . availClashErr) () conflict `thenRn_`
returnRn (addToFM_C addAvail env key elt)
| otherwise = returnRn (addToFM_C addAvail env key elt)
where
key = nameOccName (availName avail)
occ_avail = nameOccName (availName avail)
occ_ie = ieOcc ie
key
| occ_ie == occ_avail = occ_avail
| otherwise = occ_ie
-- export item is a class method, use export occ name instead.
elt = (ie,avail,reports_on)
reports_on
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment