Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
GHC
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
4,270
Issues
4,270
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
413
Merge Requests
413
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
9e715c1b
Commit
9e715c1b
authored
May 18, 2020
by
Sylvain Henry
Committed by
Marge Bot
Jun 13, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Document getPreloadUnitsAnd
parent
266bc3d9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
compiler/GHC/Unit/State.hs
compiler/GHC/Unit/State.hs
+5
-4
No files found.
compiler/GHC/Unit/State.hs
View file @
9e715c1b
...
...
@@ -2002,8 +2002,9 @@ listVisibleModuleNames dflags =
map
fst
(
filter
visible
(
Map
.
toList
(
moduleNameProvidersMap
(
unitState
dflags
))))
where
visible
(
_
,
ms
)
=
any
originVisible
(
Map
.
elems
ms
)
-- | Find all the 'UnitInfo' in both the preload packages from 'DynFlags' and corresponding to the list of
-- 'UnitInfo's
-- | Lookup 'UnitInfo' for every preload unit, for every unit used to
-- instantiate the current unit, and for every unit explicitly passed in the
-- given list of UnitId.
getPreloadUnitsAnd
::
DynFlags
->
[
UnitId
]
->
IO
[
UnitInfo
]
getPreloadUnitsAnd
dflags
pkgids0
=
let
...
...
@@ -2018,9 +2019,9 @@ getPreloadUnitsAnd dflags pkgids0 =
state
=
unitState
dflags
pkg_map
=
unitInfoMap
state
preload
=
preloadUnits
state
pa
ir
s
=
zip
pkgids
(
repeat
Nothing
)
pa
rent
s
=
zip
pkgids
(
repeat
Nothing
)
in
do
all_pkgs
<-
throwErr
dflags
(
foldM
(
add_package
dflags
pkg_map
)
preload
pa
ir
s
)
all_pkgs
<-
throwErr
dflags
(
foldM
(
add_package
dflags
pkg_map
)
preload
pa
rent
s
)
return
(
map
(
unsafeLookupUnitId
state
)
all_pkgs
)
-- Takes a list of packages, and returns the list with dependencies included,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment