Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(996)

Unified Diff: pkg/compiler/lib/src/ssa/builder.dart

Issue 2938203003: Compute KernelClosureRepresentationInfo.variableIsUsedInTryOrSync (Closed)
Patch Set: Remove test line Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/ssa/builder.dart
diff --git a/pkg/compiler/lib/src/ssa/builder.dart b/pkg/compiler/lib/src/ssa/builder.dart
index a26310f2ca6fab5c92ba57ab39e4c81f6ad26f0c..67cc6aa8c74a36dc4d659994d5c24d7ea9a71a85 100644
--- a/pkg/compiler/lib/src/ssa/builder.dart
+++ b/pkg/compiler/lib/src/ssa/builder.dart
@@ -431,8 +431,6 @@ class SsaBuilder extends ast.Visitor
bool tryInlineMethod(MethodElement element, Selector selector, TypeMask mask,
List<HInstruction> providedArguments, ast.Node currentNode,
{ResolutionInterfaceType instanceType}) {
- registry.registerStaticUse(new StaticUse.inlining(element));
-
if (nativeData.isJsInteropMember(element) &&
!element.isFactoryConstructor) {
// We only inline factory JavaScript interop constructors.
@@ -582,6 +580,8 @@ class SsaBuilder extends ast.Visitor
}
void doInlining() {
+ registry.registerStaticUse(new StaticUse.inlining(element));
Johnni Winther 2017/06/15 14:31:00 Only register when we actually inline.
+
// Add an explicit null check on the receiver before doing the
// inlining. We use [element] to get the same name in the
// NoSuchMethodError message as if we had called it.

Powered by Google App Engine
This is Rietveld 408576698