Version 3.0.4

Added Date::ResetCache() to the API so that the cached values in the Date object can be reset to allow live DST / timezone changes.

Extended existing support for printing (while debugging) the contents of objects.  Added support for printing objects from release builds.

Fixed V8 issues 989, 1006, and 1007.


git-svn-id: http://v8.googlecode.com/svn/trunk@6096 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
diff --git a/src/full-codegen.cc b/src/full-codegen.cc
index 96307a3..58540f0 100644
--- a/src/full-codegen.cc
+++ b/src/full-codegen.cc
@@ -671,8 +671,12 @@
 
 FullCodeGenerator::InlineFunctionGenerator
   FullCodeGenerator::FindInlineFunctionGenerator(Runtime::FunctionId id) {
-    return kInlineFunctionGenerators[
-      static_cast<int>(id) - static_cast<int>(Runtime::kFirstInlineFunction)];
+    int lookup_index =
+        static_cast<int>(id) - static_cast<int>(Runtime::kFirstInlineFunction);
+    ASSERT(lookup_index >= 0);
+    ASSERT(static_cast<size_t>(lookup_index) <
+           ARRAY_SIZE(kInlineFunctionGenerators));
+    return kInlineFunctionGenerators[lookup_index];
 }
 
 
@@ -684,7 +688,6 @@
   ASSERT(function->intrinsic_type == Runtime::INLINE);
   InlineFunctionGenerator generator =
       FindInlineFunctionGenerator(function->function_id);
-  ASSERT(generator != NULL);
   ((*this).*(generator))(args);
 }