Index: src/bootstrapper.cc |
diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc |
index 12a64d9eb7d3a809256402791b744ee57af1c630..a03733b7cabdf2ebfa1425d64b00ed096d9b6cb8 100644 |
--- a/src/bootstrapper.cc |
+++ b/src/bootstrapper.cc |
@@ -2742,6 +2742,15 @@ bool Genesis::InstallSpecialObjects(Handle<Context> native_context) { |
factory->stack_trace_symbol(), NONE), |
false); |
+ // Expose the internal error symbol to native JS |
+ RETURN_ON_EXCEPTION_VALUE(isolate, |
+ JSObject::SetOwnPropertyIgnoreAttributes( |
+ handle(native_context->builtins(), isolate), |
+ factory->InternalizeOneByteString( |
+ STATIC_CHAR_VECTOR("$internalErrorSymbol")), |
+ factory->internal_error_symbol(), NONE), |
+ false); |
+ |
// Expose the debug global object in global if a name for it is specified. |
if (FLAG_expose_debug_as != NULL && strlen(FLAG_expose_debug_as) != 0) { |
// If loading fails we just bail out without installing the |