Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Shayne Fletcher
Glasgow Haskell Compiler
Commits
3f20da1c
Commit
3f20da1c
authored
May 27, 2016
by
Gabor Greif
💬
Browse files
Typos in comments
parent
3a00ff92
Changes
1
Hide whitespace changes
Inline
Side-by-side
compiler/simplStg/UnariseStg.hs
View file @
3f20da1c
...
...
@@ -24,7 +24,7 @@ Suppose that a variable x : (# t1, t2 #).
* At the binding site for x, make up fresh vars x1:t1, x2:t2
* Extend the Un
i
ariseEnv x :-> [x1,x2]
* Extend the UnariseEnv x :-> [x1,x2]
* Replace the binding with a curried binding for x1,x2
Lambda: \x.e ==> \x1 x2. e
...
...
@@ -45,7 +45,7 @@ Suppose that a variable x : (# t1, t2 #).
I think we rely on the code generator to short-circuit this
case without generating any actual code.
Of course all this applies recursively, so that we flattn out nested tuples.
Of course all this applies recursively, so that we flatt
e
n out nested tuples.
Note [Unarisation and nullary tuples]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
...
...
@@ -60,7 +60,7 @@ The above scheme has a special cases for nullary unboxed tuples, x :: (# #)
* If we find (# #) as an argument all by itself
f ...(# #)...
it looks like an Id, so we look up in UnariseEnv. We want to replace it
with voidPrimId, so the convenient thing is to initalise the Un
i
ariseEnv
with voidPrimId, so the convenient thing is to initalise the UnariseEnv
with (# #) :-> [voidPrimId]
See also Note [Nullary unboxed tuple] in Type.hs.
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment