Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
GHC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dylan Yudaken
GHC
Commits
38b739b7
Commit
38b739b7
authored
15 years ago
by
Simon Marlow
Browse files
Options
Downloads
Patches
Plain Diff
Fix #3412: the worker of an Id might not be a local Id
parent
fee305ed
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
compiler/main/TidyPgm.lhs
+3
-2
3 additions, 2 deletions
compiler/main/TidyPgm.lhs
with
3 additions
and
2 deletions
compiler/main/TidyPgm.lhs
+
3
−
2
View file @
38b739b7
...
@@ -613,7 +613,7 @@ chooseExternalIds hsc_env mod omit_prags binds
...
@@ -613,7 +613,7 @@ chooseExternalIds hsc_env mod omit_prags binds
| otherwise = do
| otherwise = do
(occ_env', name') <- tidyTopName mod nc_var (Just referrer) occ_env id
(occ_env', name') <- tidyTopName mod nc_var (Just referrer) occ_env id
let
let
rhs = expectJust "chooseExternalIds
"
$ lookupVarEnv bind_env id
rhs = expectJust
(showSDoc (text
"chooseExternalIds
: " <> ppr id))
$ lookupVarEnv bind_env id
(new_ids, show_unfold)
(new_ids, show_unfold)
| omit_prags = ([], False)
| omit_prags = ([], False)
| otherwise = addExternal id rhs
| otherwise = addExternal id rhs
...
@@ -635,7 +635,8 @@ addExternal :: Id -> CoreExpr -> ([Id],Bool)
...
@@ -635,7 +635,8 @@ addExternal :: Id -> CoreExpr -> ([Id],Bool)
addExternal id rhs = (new_needed_ids, show_unfold)
addExternal id rhs = (new_needed_ids, show_unfold)
where
where
new_needed_ids = unfold_ids ++
new_needed_ids = unfold_ids ++
filter (not . (`elemVarSet` unfold_set))
filter (\id -> isLocalId id &&
not (id `elemVarSet` unfold_set))
(varSetElems worker_ids ++
(varSetElems worker_ids ++
varSetElems spec_ids) -- XXX non-det ordering
varSetElems spec_ids) -- XXX non-det ordering
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment