Author: [EMAIL PROTECTED]
Date: Mon Oct 27 05:24:22 2008
New Revision: 602
Modified:
branches/bleeding_edge/src/objects.cc
branches/bleeding_edge/src/runtime.cc
Log:
Rewrites a ternary choice operator to fix a compiler
linkage bug.
Review URL: http://codereview.chromium.org/8189
Modified: branches/bleeding_edge/src/objects.cc
==============================================================================
--- branches/bleeding_edge/src/objects.cc (original)
+++ branches/bleeding_edge/src/objects.cc Mon Oct 27 05:24:22 2008
@@ -6789,6 +6789,4 @@
}
-const int FunctionTemplateInfo::kSize;
-const int ObjectTemplateInfo::kSize;
} } // namespace v8::internal
Modified: branches/bleeding_edge/src/runtime.cc
==============================================================================
--- branches/bleeding_edge/src/runtime.cc (original)
+++ branches/bleeding_edge/src/runtime.cc Mon Oct 27 05:24:22 2008
@@ -327,8 +327,11 @@
RUNTIME_ASSERT(type == FUNCTION_TEMPLATE_INFO_TYPE ||
type == OBJECT_TEMPLATE_INFO_TYPE);
RUNTIME_ASSERT(offset > 0);
- RUNTIME_ASSERT(offset < ((type == FUNCTION_TEMPLATE_INFO_TYPE) ?
- FunctionTemplateInfo::kSize : ObjectTemplateInfo::kSize));
+ if (type == FUNCTION_TEMPLATE_INFO_TYPE) {
+ RUNTIME_ASSERT(offset < FunctionTemplateInfo::kSize);
+ } else {
+ RUNTIME_ASSERT(offset < ObjectTemplateInfo::kSize);
+ }
return HeapObject::RawField(templ, offset);
}
--~--~---------~--~----~------------~-------~--~----~
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
-~----------~----~----~----~------~----~------~--~---