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

Side by Side Diff: src/handles.cc

Issue 1327002: Simplify passing of AccessorInfo to interceptors: (Closed)
Patch Set: . Created 10 years, 9 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
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 521 matching lines...) Expand 10 before | Expand all | Expand 10 after
532 } 532 }
533 if (source->Get(pos) == '\n') { 533 if (source->Get(pos) == '\n') {
534 line++; 534 line++;
535 } 535 }
536 } 536 }
537 return line; 537 return line;
538 } 538 }
539 539
540 540
541 void CustomArguments::IterateInstance(ObjectVisitor* v) { 541 void CustomArguments::IterateInstance(ObjectVisitor* v) {
542 v->VisitPointers(values_, values_ + 4); 542 v->VisitPointers(values_, values_ + 3);
543 } 543 }
544 544
545 545
546 // Compute the property keys from the interceptor. 546 // Compute the property keys from the interceptor.
547 v8::Handle<v8::Array> GetKeysForNamedInterceptor(Handle<JSObject> receiver, 547 v8::Handle<v8::Array> GetKeysForNamedInterceptor(Handle<JSObject> receiver,
548 Handle<JSObject> object) { 548 Handle<JSObject> object) {
549 Handle<InterceptorInfo> interceptor(object->GetNamedInterceptor()); 549 Handle<InterceptorInfo> interceptor(object->GetNamedInterceptor());
550 CustomArguments args(interceptor->data(), *receiver, *object); 550 CustomArguments args(interceptor->data(), *receiver, *object);
551 v8::AccessorInfo info(args.end()); 551 v8::AccessorInfo info(args.end());
552 v8::Handle<v8::Array> result; 552 v8::Handle<v8::Array> result;
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
862 Handle<Map> new_map = Factory::CopyMapDropTransitions(old_map); 862 Handle<Map> new_map = Factory::CopyMapDropTransitions(old_map);
863 obj->set_map(*new_map); 863 obj->set_map(*new_map);
864 new_map->set_needs_loading(true); 864 new_map->set_needs_loading(true);
865 // Store the lazy loading info in the constructor field. We'll 865 // Store the lazy loading info in the constructor field. We'll
866 // reestablish the constructor from the fixed array after loading. 866 // reestablish the constructor from the fixed array after loading.
867 new_map->set_constructor(*arr); 867 new_map->set_constructor(*arr);
868 ASSERT(!obj->IsLoaded()); 868 ASSERT(!obj->IsLoaded());
869 } 869 }
870 870
871 } } // namespace v8::internal 871 } } // namespace v8::internal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698