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

Side by Side Diff: src/objects-inl.h

Issue 23757017: remove Isolate::Current from most files starting with 'o' through 'r' (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 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 | « src/objects-debug.cc ('k') | src/parser.h » ('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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 899 matching lines...) Expand 10 before | Expand all | Expand 10 after
910 } 910 }
911 return Failure::Exception(); 911 return Failure::Exception();
912 } 912 }
913 913
914 914
915 bool Object::HasSpecificClassOf(String* name) { 915 bool Object::HasSpecificClassOf(String* name) {
916 return this->IsJSObject() && (JSObject::cast(this)->class_name() == name); 916 return this->IsJSObject() && (JSObject::cast(this)->class_name() == name);
917 } 917 }
918 918
919 919
920 MaybeObject* Object::GetElement(uint32_t index) { 920 MaybeObject* Object::GetElement(Isolate* isolate, uint32_t index) {
921 // GetElement can trigger a getter which can cause allocation. 921 // GetElement can trigger a getter which can cause allocation.
922 // This was not always the case. This ASSERT is here to catch 922 // This was not always the case. This ASSERT is here to catch
923 // leftover incorrect uses. 923 // leftover incorrect uses.
924 ASSERT(AllowHeapAllocation::IsAllowed()); 924 ASSERT(AllowHeapAllocation::IsAllowed());
925 return GetElementWithReceiver(this, index); 925 return GetElementWithReceiver(isolate, this, index);
926 } 926 }
927 927
928 928
929 Object* Object::GetElementNoExceptionThrown(uint32_t index) { 929 Object* Object::GetElementNoExceptionThrown(Isolate* isolate, uint32_t index) {
930 MaybeObject* maybe = GetElementWithReceiver(this, index); 930 MaybeObject* maybe = GetElementWithReceiver(isolate, this, index);
931 ASSERT(!maybe->IsFailure()); 931 ASSERT(!maybe->IsFailure());
932 Object* result = NULL; // Initialization to please compiler. 932 Object* result = NULL; // Initialization to please compiler.
933 maybe->ToObject(&result); 933 maybe->ToObject(&result);
934 return result; 934 return result;
935 } 935 }
936 936
937 937
938 MaybeObject* Object::GetProperty(Name* key) { 938 MaybeObject* Object::GetProperty(Name* key) {
939 PropertyAttributes attributes; 939 PropertyAttributes attributes;
940 return GetPropertyWithReceiver(this, key, &attributes); 940 return GetPropertyWithReceiver(this, key, &attributes);
(...skipping 3892 matching lines...) Expand 10 before | Expand all | Expand 10 after
4833 CONDITIONAL_WRITE_BARRIER(GetHeap(), 4833 CONDITIONAL_WRITE_BARRIER(GetHeap(),
4834 this, 4834 this,
4835 kScopeInfoOffset, 4835 kScopeInfoOffset,
4836 reinterpret_cast<Object*>(value), 4836 reinterpret_cast<Object*>(value),
4837 mode); 4837 mode);
4838 } 4838 }
4839 4839
4840 4840
4841 bool SharedFunctionInfo::is_compiled() { 4841 bool SharedFunctionInfo::is_compiled() {
4842 return code() != 4842 return code() !=
4843 Isolate::Current()->builtins()->builtin(Builtins::kLazyCompile); 4843 GetIsolate()->builtins()->builtin(Builtins::kLazyCompile);
4844 } 4844 }
4845 4845
4846 4846
4847 bool SharedFunctionInfo::IsApiFunction() { 4847 bool SharedFunctionInfo::IsApiFunction() {
4848 return function_data()->IsFunctionTemplateInfo(); 4848 return function_data()->IsFunctionTemplateInfo();
4849 } 4849 }
4850 4850
4851 4851
4852 FunctionTemplateInfo* SharedFunctionInfo::get_api_func_data() { 4852 FunctionTemplateInfo* SharedFunctionInfo::get_api_func_data() {
4853 ASSERT(IsApiFunction()); 4853 ASSERT(IsApiFunction());
(...skipping 1431 matching lines...) Expand 10 before | Expand all | Expand 10 after
6285 #undef WRITE_UINT32_FIELD 6285 #undef WRITE_UINT32_FIELD
6286 #undef READ_SHORT_FIELD 6286 #undef READ_SHORT_FIELD
6287 #undef WRITE_SHORT_FIELD 6287 #undef WRITE_SHORT_FIELD
6288 #undef READ_BYTE_FIELD 6288 #undef READ_BYTE_FIELD
6289 #undef WRITE_BYTE_FIELD 6289 #undef WRITE_BYTE_FIELD
6290 6290
6291 6291
6292 } } // namespace v8::internal 6292 } } // namespace v8::internal
6293 6293
6294 #endif // V8_OBJECTS_INL_H_ 6294 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects-debug.cc ('k') | src/parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698