aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/typer/Inliner.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2016-09-02 17:23:54 +0200
committerMartin Odersky <odersky@gmail.com>2016-10-02 16:11:21 +0200
commit96d057364703a9b89ca49f2ac16f2cdb140d396d (patch)
treee597ebb61fc730c3c1ba6c08fd027f7712adecb1 /src/dotty/tools/dotc/typer/Inliner.scala
parenta47a8008023ea04ff7f8d708567fb6a2c516caaa (diff)
downloaddotty-96d057364703a9b89ca49f2ac16f2cdb140d396d.tar.gz
dotty-96d057364703a9b89ca49f2ac16f2cdb140d396d.tar.bz2
dotty-96d057364703a9b89ca49f2ac16f2cdb140d396d.zip
Support separate compilation
Inline trees can now be read form TASTY. However, positions are not set correctly. This remains to be implemented.
Diffstat (limited to 'src/dotty/tools/dotc/typer/Inliner.scala')
-rw-r--r--src/dotty/tools/dotc/typer/Inliner.scala6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/dotty/tools/dotc/typer/Inliner.scala b/src/dotty/tools/dotc/typer/Inliner.scala
index 06eea9113..68bc55860 100644
--- a/src/dotty/tools/dotc/typer/Inliner.scala
+++ b/src/dotty/tools/dotc/typer/Inliner.scala
@@ -82,12 +82,12 @@ object Inliner {
| You can use -Xmax:inlines to change the limit.""")
}
- def dropInlined(tree: tpd.Inlined)(implicit ctx: Context): Tree = {
+ def dropInlined(inlined: tpd.Inlined)(implicit ctx: Context): Tree = {
val reposition = new TreeMap {
override def transform(tree: Tree)(implicit ctx: Context): Tree =
- tree.withPos(tree.pos)
+ tree.withPos(inlined.call.pos)
}
- tpd.seq(tree.bindings, reposition.transform(tree.expansion))
+ tpd.seq(inlined.bindings, reposition.transform(inlined.expansion))
}
def inlineContext(tree: untpd.Inlined)(implicit ctx: Context): Context =