Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(115)

Side by Side Diff: src/builtins.cc

Issue 7066018: Merge r8032 to the 3.2 branch (Closed) Base URL: http://v8.googlecode.com/svn/branches/3.2/
Patch Set: Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | src/version.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 if (array_proto->elements() != heap->empty_fixed_array()) return false; 371 if (array_proto->elements() != heap->empty_fixed_array()) return false;
372 // Hidden prototype 372 // Hidden prototype
373 array_proto = JSObject::cast(array_proto->GetPrototype()); 373 array_proto = JSObject::cast(array_proto->GetPrototype());
374 ASSERT(array_proto->elements() == heap->empty_fixed_array()); 374 ASSERT(array_proto->elements() == heap->empty_fixed_array());
375 // Object.prototype 375 // Object.prototype
376 Object* proto = array_proto->GetPrototype(); 376 Object* proto = array_proto->GetPrototype();
377 if (proto == heap->null_value()) return false; 377 if (proto == heap->null_value()) return false;
378 array_proto = JSObject::cast(proto); 378 array_proto = JSObject::cast(proto);
379 if (array_proto != global_context->initial_object_prototype()) return false; 379 if (array_proto != global_context->initial_object_prototype()) return false;
380 if (array_proto->elements() != heap->empty_fixed_array()) return false; 380 if (array_proto->elements() != heap->empty_fixed_array()) return false;
381 ASSERT(array_proto->GetPrototype()->IsNull()); 381 return array_proto->GetPrototype()->IsNull();
382 return true;
383 } 382 }
384 383
385 384
386 MUST_USE_RESULT 385 MUST_USE_RESULT
387 static inline MaybeObject* EnsureJSArrayWithWritableFastElements( 386 static inline MaybeObject* EnsureJSArrayWithWritableFastElements(
388 Heap* heap, Object* receiver) { 387 Heap* heap, Object* receiver) {
389 if (!receiver->IsJSArray()) return NULL; 388 if (!receiver->IsJSArray()) return NULL;
390 JSArray* array = JSArray::cast(receiver); 389 JSArray* array = JSArray::cast(receiver);
391 HeapObject* elms = array->elements(); 390 HeapObject* elms = array->elements();
392 if (elms->map() == heap->fixed_array_map()) return elms; 391 if (elms->map() == heap->fixed_array_map()) return elms;
(...skipping 1306 matching lines...) Expand 10 before | Expand all | Expand 10 after
1699 return Handle<Code>(code_address); \ 1698 return Handle<Code>(code_address); \
1700 } 1699 }
1701 BUILTIN_LIST_C(DEFINE_BUILTIN_ACCESSOR_C) 1700 BUILTIN_LIST_C(DEFINE_BUILTIN_ACCESSOR_C)
1702 BUILTIN_LIST_A(DEFINE_BUILTIN_ACCESSOR_A) 1701 BUILTIN_LIST_A(DEFINE_BUILTIN_ACCESSOR_A)
1703 BUILTIN_LIST_DEBUG_A(DEFINE_BUILTIN_ACCESSOR_A) 1702 BUILTIN_LIST_DEBUG_A(DEFINE_BUILTIN_ACCESSOR_A)
1704 #undef DEFINE_BUILTIN_ACCESSOR_C 1703 #undef DEFINE_BUILTIN_ACCESSOR_C
1705 #undef DEFINE_BUILTIN_ACCESSOR_A 1704 #undef DEFINE_BUILTIN_ACCESSOR_A
1706 1705
1707 1706
1708 } } // namespace v8::internal 1707 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/version.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698