Commit d8e1c0a7 authored by simonpj's avatar simonpj
Browse files

[project @ 2000-09-11 08:13:37 by simonpj]

Remove redundant setNoDiscardId call from Specialise.newIdSM
parent 2213195a
......@@ -1140,15 +1140,12 @@ newIdSM old_id new_ty
= getUniqSM `thenSM` \ uniq ->
-- Give the new Id a similar occurrence name to the old one
-- We used to add setIdNoDiscard if the old id was exported, to
-- avoid it being dropped as dead code, but that's not necessary any more.
name = idName old_id
new_id = mkUserLocal (mkSpecOcc (nameOccName name)) uniq new_ty (getSrcLoc name)
-- If the old Id was exported, make the new one non-discardable,
-- else we will discard it since it doesn't seem to be called.
new_id' | isExportedId old_id = setIdNoDiscard new_id
| otherwise = new_id
returnSM new_id'
returnSM new_id
= getUniqSM `thenSM` \ uniq ->
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