| 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 826 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 837 | 837 |
| 838 // Disable breakpoints and interrupts while compiling and running the | 838 // Disable breakpoints and interrupts while compiling and running the |
| 839 // debugger scripts including the context creation code. | 839 // debugger scripts including the context creation code. |
| 840 DisableBreak disable(true); | 840 DisableBreak disable(true); |
| 841 PostponeInterruptsScope postpone(isolate_); | 841 PostponeInterruptsScope postpone(isolate_); |
| 842 | 842 |
| 843 // Create the debugger context. | 843 // Create the debugger context. |
| 844 HandleScope scope(isolate_); | 844 HandleScope scope(isolate_); |
| 845 Handle<Context> context = | 845 Handle<Context> context = |
| 846 isolate_->bootstrapper()->CreateEnvironment( | 846 isolate_->bootstrapper()->CreateEnvironment( |
| 847 isolate_, |
| 847 Handle<Object>::null(), | 848 Handle<Object>::null(), |
| 848 v8::Handle<ObjectTemplate>(), | 849 v8::Handle<ObjectTemplate>(), |
| 849 NULL); | 850 NULL); |
| 850 | 851 |
| 851 // Use the debugger context. | 852 // Use the debugger context. |
| 852 SaveContext save(isolate_); | 853 SaveContext save(isolate_); |
| 853 isolate_->set_context(*context); | 854 isolate_->set_context(*context); |
| 854 | 855 |
| 855 // Expose the builtins object in the debugger context. | 856 // Expose the builtins object in the debugger context. |
| 856 Handle<String> key = isolate_->factory()->LookupAsciiSymbol("builtins"); | 857 Handle<String> key = isolate_->factory()->LookupAsciiSymbol("builtins"); |
| (...skipping 2322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3179 { | 3180 { |
| 3180 Locker locker; | 3181 Locker locker; |
| 3181 Isolate::Current()->debugger()->CallMessageDispatchHandler(); | 3182 Isolate::Current()->debugger()->CallMessageDispatchHandler(); |
| 3182 } | 3183 } |
| 3183 } | 3184 } |
| 3184 } | 3185 } |
| 3185 | 3186 |
| 3186 #endif // ENABLE_DEBUGGER_SUPPORT | 3187 #endif // ENABLE_DEBUGGER_SUPPORT |
| 3187 | 3188 |
| 3188 } } // namespace v8::internal | 3189 } } // namespace v8::internal |
| OLD | NEW |