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
Model registry
Operate
Terraform modules
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
Dominik Schrempf
GHC
Commits
765c1de8
Commit
765c1de8
authored
1 year ago
by
Ackerman
Committed by
Ben Gamari
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
Introduce genLHsApp and genLHsLit helpers in GHC.Rename.Utils
(cherry picked from commit
3efe7f39
)
parent
c505474d
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/GHC/Rename/Utils.hs
+10
-3
10 additions, 3 deletions
compiler/GHC/Rename/Utils.hs
with
10 additions
and
3 deletions
compiler/GHC/Rename/Utils.hs
+
10
−
3
View file @
765c1de8
...
...
@@ -18,8 +18,9 @@ module GHC.Rename.Utils (
warnForallIdentifier
,
checkUnusedRecordWildcard
,
badQualBndrErr
,
typeAppErr
,
badFieldConErr
,
wrapGenSpan
,
genHsVar
,
genLHsVar
,
genHsApp
,
genHsApps
,
genAppType
,
genHsIntegralLit
,
genHsTyLit
,
genSimpleConPat
,
wrapGenSpan
,
genHsVar
,
genLHsVar
,
genHsApp
,
genHsApps
,
genLHsApp
,
genAppType
,
genLHsLit
,
genHsIntegralLit
,
genHsTyLit
,
genSimpleConPat
,
genVarPat
,
genWildPat
,
genSimpleFunBind
,
genFunBind
,
...
...
@@ -572,6 +573,9 @@ genHsApps fun args = foldl genHsApp (genHsVar fun) args
genHsApp
::
HsExpr
GhcRn
->
LHsExpr
GhcRn
->
HsExpr
GhcRn
genHsApp
fun
arg
=
HsApp
noAnn
(
wrapGenSpan
fun
)
arg
genLHsApp
::
HsExpr
GhcRn
->
LHsExpr
GhcRn
->
LHsExpr
GhcRn
genLHsApp
fun
arg
=
wrapGenSpan
(
genHsApp
fun
arg
)
genLHsVar
::
Name
->
LHsExpr
GhcRn
genLHsVar
nm
=
wrapGenSpan
$
genHsVar
nm
...
...
@@ -581,8 +585,11 @@ genHsVar nm = HsVar noExtField $ wrapGenSpan nm
genAppType
::
HsExpr
GhcRn
->
HsType
(
NoGhcTc
GhcRn
)
->
HsExpr
GhcRn
genAppType
expr
ty
=
HsAppType
noExtField
(
wrapGenSpan
expr
)
noHsTok
(
mkEmptyWildCardBndrs
(
wrapGenSpan
ty
))
genLHsLit
::
HsLit
GhcRn
->
LocatedAn
an
(
HsExpr
GhcRn
)
genLHsLit
=
wrapGenSpan
.
HsLit
noAnn
genHsIntegralLit
::
IntegralLit
->
LocatedAn
an
(
HsExpr
GhcRn
)
genHsIntegralLit
lit
=
wrapGenSpan
$
HsLit
noAnn
(
HsInt
noExtField
lit
)
genHsIntegralLit
=
genLHsLit
.
HsInt
noExtField
genHsTyLit
::
FastString
->
HsType
GhcRn
genHsTyLit
=
HsTyLit
noExtField
.
HsStrTy
NoSourceText
...
...
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