OLD | NEW |
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 629 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
640 Handle<JSObject> arguments_boilerplate = Handle<JSObject>( | 640 Handle<JSObject> arguments_boilerplate = Handle<JSObject>( |
641 isolate->context()->native_context()->arguments_boilerplate(), | 641 isolate->context()->native_context()->arguments_boilerplate(), |
642 isolate); | 642 isolate); |
643 Handle<JSFunction> arguments_function = Handle<JSFunction>( | 643 Handle<JSFunction> arguments_function = Handle<JSFunction>( |
644 JSFunction::cast(arguments_boilerplate->map()->constructor()), | 644 JSFunction::cast(arguments_boilerplate->map()->constructor()), |
645 isolate); | 645 isolate); |
646 | 646 |
647 // Only collect keys if access is permitted. | 647 // Only collect keys if access is permitted. |
648 for (Handle<Object> p = object; | 648 for (Handle<Object> p = object; |
649 *p != isolate->heap()->null_value(); | 649 *p != isolate->heap()->null_value(); |
650 p = Handle<Object>(p->GetPrototype(), isolate)) { | 650 p = Handle<Object>(p->GetPrototype(isolate), isolate)) { |
651 if (p->IsJSProxy()) { | 651 if (p->IsJSProxy()) { |
652 Handle<JSProxy> proxy(JSProxy::cast(*p), isolate); | 652 Handle<JSProxy> proxy(JSProxy::cast(*p), isolate); |
653 Handle<Object> args[] = { proxy }; | 653 Handle<Object> args[] = { proxy }; |
654 Handle<Object> names = Execution::Call( | 654 Handle<Object> names = Execution::Call( |
655 isolate->proxy_enumerate(), object, ARRAY_SIZE(args), args, threw); | 655 isolate->proxy_enumerate(), object, ARRAY_SIZE(args), args, threw); |
656 if (*threw) return content; | 656 if (*threw) return content; |
657 content = AddKeysFromJSArray(content, Handle<JSArray>::cast(names)); | 657 content = AddKeysFromJSArray(content, Handle<JSArray>::cast(names)); |
658 break; | 658 break; |
659 } | 659 } |
660 | 660 |
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
926 data->next = prev_next_; | 926 data->next = prev_next_; |
927 data->limit = prev_limit_; | 927 data->limit = prev_limit_; |
928 #ifdef DEBUG | 928 #ifdef DEBUG |
929 handles_detached_ = true; | 929 handles_detached_ = true; |
930 #endif | 930 #endif |
931 return deferred; | 931 return deferred; |
932 } | 932 } |
933 | 933 |
934 | 934 |
935 } } // namespace v8::internal | 935 } } // namespace v8::internal |
OLD | NEW |