Skip to content
Snippets Groups Projects
Commit 6bd54856 authored by Manos Koukoutos's avatar Manos Koukoutos
Browse files

Preserve position in FunctionClosure

parent f727a8fa
No related branches found
No related tags found
No related merge requests found
......@@ -75,7 +75,7 @@ object FunctionClosure extends TransformationPhase {
// println(from.uniqueName + " -> " + to.uniqueName)
//}
f.fullBody = preMap {
case FunctionInvocation(tfd, args) if closed contains tfd.fd =>
case fi@FunctionInvocation(tfd, args) if closed contains tfd.fd =>
val FunSubst(newFd, newParams, newTParams) = closed(tfd.fd)
// New -> old map for function call
......@@ -94,7 +94,7 @@ object FunctionClosure extends TransformationPhase {
Some(FunctionInvocation(
newFd.typed(tfd.tps ++ tFinalExtra),
args ++ extraArgs
))
).copiedFrom(fi))
case _ => None
}(f.fullBody)
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment