| Index: runtime/vm/object.cc
|
| diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
|
| index 0886a30ee2dca5a75bbf024e7550dc68db4a360f..003f0b80ddbcdd2c6eec28d4f264f11eec9aebfb 100644
|
| --- a/runtime/vm/object.cc
|
| +++ b/runtime/vm/object.cc
|
| @@ -3088,6 +3088,13 @@ RawObject* Class::Evaluate(const String& expr,
|
| const Array& param_names,
|
| const Array& param_values) const {
|
| ASSERT(Thread::Current()->IsMutatorThread());
|
| + if (id() < kInstanceCid) {
|
| + const Instance& exception = Instance::Handle(String::New(
|
| + "Cannot evaluate against a VM internal class"));
|
| + const Instance& stacktrace = Instance::Handle();
|
| + return UnhandledException::New(exception, stacktrace);
|
| + }
|
| +
|
| const Function& eval_func =
|
| Function::Handle(EvaluateHelper(*this, expr, param_names, true));
|
| const Object& result =
|
|
|