OLD | NEW |
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 790 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
801 FACTORY->NewFunctionFromSharedFunctionInfo(function_info, context); | 801 FACTORY->NewFunctionFromSharedFunctionInfo(function_info, context); |
802 Handle<Object> result = | 802 Handle<Object> result = |
803 Execution::TryCall(function, Handle<Object>(context->global()), | 803 Execution::TryCall(function, Handle<Object>(context->global()), |
804 0, NULL, &caught_exception); | 804 0, NULL, &caught_exception); |
805 | 805 |
806 // Check for caught exceptions. | 806 // Check for caught exceptions. |
807 if (caught_exception) { | 807 if (caught_exception) { |
808 Handle<Object> message = MessageHandler::MakeMessageObject( | 808 Handle<Object> message = MessageHandler::MakeMessageObject( |
809 "error_loading_debugger", NULL, Vector<Handle<Object> >::empty(), | 809 "error_loading_debugger", NULL, Vector<Handle<Object> >::empty(), |
810 Handle<String>(), Handle<JSArray>()); | 810 Handle<String>(), Handle<JSArray>()); |
811 MessageHandler::ReportMessage(NULL, message); | 811 MessageHandler::ReportMessage(Isolate::Current(), NULL, message); |
812 return false; | 812 return false; |
813 } | 813 } |
814 | 814 |
815 // Mark this script as native and return successfully. | 815 // Mark this script as native and return successfully. |
816 Handle<Script> script(Script::cast(function->shared()->script())); | 816 Handle<Script> script(Script::cast(function->shared()->script())); |
817 script->set_type(Smi::FromInt(Script::TYPE_NATIVE)); | 817 script->set_type(Smi::FromInt(Script::TYPE_NATIVE)); |
818 return true; | 818 return true; |
819 } | 819 } |
820 | 820 |
821 | 821 |
(...skipping 2340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3162 { | 3162 { |
3163 Locker locker; | 3163 Locker locker; |
3164 Isolate::Current()->debugger()->CallMessageDispatchHandler(); | 3164 Isolate::Current()->debugger()->CallMessageDispatchHandler(); |
3165 } | 3165 } |
3166 } | 3166 } |
3167 } | 3167 } |
3168 | 3168 |
3169 #endif // ENABLE_DEBUGGER_SUPPORT | 3169 #endif // ENABLE_DEBUGGER_SUPPORT |
3170 | 3170 |
3171 } } // namespace v8::internal | 3171 } } // namespace v8::internal |
OLD | NEW |