diff options
author | Martin Odersky <odersky@gmail.com> | 2016-09-09 18:39:49 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2016-10-02 16:11:21 +0200 |
commit | b1cda4fadcb586a82b546751d5cc426cd5382cd5 (patch) | |
tree | 9d14f1ab02caa846d347033cf444c6e68b1ea746 /src/dotty/tools/dotc/typer/Typer.scala | |
parent | c9e45de0042e9a50397bf922d812d764b36e4d12 (diff) | |
download | dotty-b1cda4fadcb586a82b546751d5cc426cd5382cd5.tar.gz dotty-b1cda4fadcb586a82b546751d5cc426cd5382cd5.tar.bz2 dotty-b1cda4fadcb586a82b546751d5cc426cd5382cd5.zip |
Better names and documentation for Inliner.
Diffstat (limited to 'src/dotty/tools/dotc/typer/Typer.scala')
-rw-r--r-- | src/dotty/tools/dotc/typer/Typer.scala | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/dotty/tools/dotc/typer/Typer.scala b/src/dotty/tools/dotc/typer/Typer.scala index b7b61e8de..8830537e3 100644 --- a/src/dotty/tools/dotc/typer/Typer.scala +++ b/src/dotty/tools/dotc/typer/Typer.scala @@ -1169,7 +1169,7 @@ class Typer extends Namer with TypeAssigner with Applications with Implicits wit // Overwrite inline body to make sure it is not evaluated twice sym.getAnnotation(defn.InlineAnnot) match { - case Some(ann) => Inliner.attachBody(ann, ctx => rhs1) + case Some(ann) => Inliner.attachInlineInfo(ann, ctx => rhs1) case _ => } @@ -1495,7 +1495,7 @@ class Typer extends Namer with TypeAssigner with Applications with Implicits wit case none => val mdef1 = typed(mdef) buf += mdef1 - if (Inliner.hasInlinedBody(mdef1.symbol)) + if (Inliner.hasBodyToInline(mdef1.symbol)) buf ++= Inliner.inlineAccessors(mdef1.symbol) traverse(rest) } @@ -1796,7 +1796,7 @@ class Typer extends Namer with TypeAssigner with Applications with Implicits wit tree } else if (tree.tpe <:< pt) - if (Inliner.hasInlinedBody(tree.symbol) && + if (Inliner.hasBodyToInline(tree.symbol) && !ctx.owner.ownersIterator.exists(_.isInlineMethod) && !ctx.settings.YnoInline.value && !ctx.isAfterTyper) |