Skip to content
GitLab
Menu
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
9685c129
Commit
9685c129
authored
Jul 16, 2007
by
rl@cse.unsw.edu.au
Browse files
Add support for name cloning to vectorisation monad
parent
8776493a
Changes
1
Hide whitespace changes
Inline
Side-by-side
compiler/vectorise/VectMonad.hs
View file @
9685c129
...
...
@@ -31,6 +31,7 @@ import Type
import
Var
import
VarEnv
import
Id
import
OccName
import
Name
import
NameEnv
...
...
@@ -240,6 +241,16 @@ getInstEnv = readGEnv global_inst_env
getFamInstEnv
::
VM
FamInstEnvs
getFamInstEnv
=
readGEnv
global_fam_inst_env
cloneName
::
(
OccName
->
OccName
)
->
Name
->
VM
Name
cloneName
mk_occ
name
=
liftM
make
(
liftDs
newUnique
)
where
occ_name
=
mk_occ
(
nameOccName
name
)
make
u
|
isExternalName
name
=
mkExternalName
u
(
nameModule
name
)
occ_name
(
nameSrcSpan
name
)
|
otherwise
=
mkSystemName
u
occ_name
newLocalVar
::
FastString
->
Type
->
VM
Var
newLocalVar
fs
ty
=
do
...
...
Write
Preview
Supports
Markdown
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