From a794f6f1e13a0d112c0673a39e8686c546c49333 Mon Sep 17 00:00:00 2001
From: "Paolo G. Giarrusso"
Date: Thu, 5 Jul 2018 21:47:34 +0200
Subject: [PATCH] WIP try fixing #4765
---
compiler/src/dotty/tools/dotc/typer/Inliner.scala | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/compiler/src/dotty/tools/dotc/typer/Inliner.scala b/compiler/src/dotty/tools/dotc/typer/Inliner.scala
index cd55764631a6..e69f64e32b09 100644
--- a/compiler/src/dotty/tools/dotc/typer/Inliner.scala
+++ b/compiler/src/dotty/tools/dotc/typer/Inliner.scala
@@ -420,7 +420,7 @@ class Inliner(call: tpd.Tree, rhsToInline: tpd.Tree)(implicit ctx: Context) {
/** The Inlined node representing the inlined call */
def inlined(pt: Type) = {
// make sure prefix is executed if it is impure
- if (!isIdempotentExpr(prefix)) registerType(meth.owner.thisType)
+ if (!isPureExpr(prefix)) registerType(meth.owner.thisType)
// Register types of all leaves of inlined body so that the `paramProxy` and `thisProxy` maps are defined.
rhsToInline.foreachSubTree(registerLeaf)