Revision: 8285
Author:   [email protected]
Date:     Tue Jun 14 12:26:09 2011
Log:      Fix invalid assertion.

Runtime_DeclareContextSlot is used to declare global variables.

[email protected]
BUG=
TEST=

Review URL: http://codereview.chromium.org/7158001
http://code.google.com/p/v8/source/detail?r=8285

Modified:
 /branches/bleeding_edge/src/runtime.cc

=======================================
--- /branches/bleeding_edge/src/runtime.cc      Tue Jun 14 08:00:57 2011
+++ /branches/bleeding_edge/src/runtime.cc      Tue Jun 14 12:26:09 2011
@@ -1232,7 +1232,7 @@

   // Declarations are always done in the function context.
   context = Handle<Context>(context->fcontext());
-  ASSERT(context->IsFunctionContext());
+  ASSERT(context->IsFunctionContext() || context->IsGlobalContext());

   int index;
   PropertyAttributes attributes;

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to