Rewrites a ternary choice operator to fix a compiler
linkage bug. Review URL: http://codereview.chromium.org/8189 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@602 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
6941a4f389
commit
724f5648b9
@ -6789,6 +6789,4 @@ int BreakPointInfo::GetBreakPointCount() {
|
||||
}
|
||||
|
||||
|
||||
const int FunctionTemplateInfo::kSize;
|
||||
const int ObjectTemplateInfo::kSize;
|
||||
} } // namespace v8::internal
|
||||
|
@ -327,8 +327,11 @@ static Object* Runtime_GetTemplateField(Arguments args) {
|
||||
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);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user