Index: src/accessors.cc |
diff --git a/src/accessors.cc b/src/accessors.cc |
index 00ff201a744df7e194ab541602a9f681057735b3..9bc728d3116f4349dc1fd4bcfb42003aa292d382 100644 |
--- a/src/accessors.cc |
+++ b/src/accessors.cc |
@@ -600,7 +600,10 @@ MaybeObject* Accessors::FunctionSetPrototype(Isolate* isolate, |
} |
Handle<Object> old_value; |
- bool is_observed = *function == *object && function->map()->is_observed(); |
+ bool is_observed = |
+ FLAG_harmony_observation && |
+ *function == *object && |
+ function->map()->is_observed(); |
if (is_observed) { |
if (function->has_prototype()) |
old_value = handle(function->prototype(), isolate); |