Index: runtime/vm/weak_code.cc |
diff --git a/runtime/vm/weak_code.cc b/runtime/vm/weak_code.cc |
index d68cfff89d3fe34e3d1226ceafa39482889ecc4a..1305443c33e909a57ffd00c6c814fd5c2ace3cb3 100644 |
--- a/runtime/vm/weak_code.cc |
+++ b/runtime/vm/weak_code.cc |
@@ -113,6 +113,7 @@ void WeakCodeReferences::DisableCode() { |
function.SwitchToUnoptimizedCode(); |
} else if (function.unoptimized_code() == code.raw()) { |
ReportSwitchingCode(code); |
+ function.set_was_compiled(false); |
function.ClearICDataArray(); |
// Remove the code object from the function. The next time the |
// function is invoked, it will be compiled again. |