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 12182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
12193 } | 12193 } |
12194 two_byte_content_[14] = 'b'; | 12194 two_byte_content_[14] = 'b'; |
12195 | 12195 |
12196 // Create the input string for the regexp - the one we are going to change | 12196 // Create the input string for the regexp - the one we are going to change |
12197 // properties of. | 12197 // properties of. |
12198 input_ = FACTORY->NewExternalStringFromAscii(&ascii_resource_); | 12198 input_ = FACTORY->NewExternalStringFromAscii(&ascii_resource_); |
12199 | 12199 |
12200 // Inject the input as a global variable. | 12200 // Inject the input as a global variable. |
12201 i::Handle<i::String> input_name = | 12201 i::Handle<i::String> input_name = |
12202 FACTORY->NewStringFromAscii(i::Vector<const char>("input", 5)); | 12202 FACTORY->NewStringFromAscii(i::Vector<const char>("input", 5)); |
12203 i::Isolate::Current()->native_context()->global()->SetProperty( | 12203 i::Isolate::Current()->native_context()->global_object()->SetProperty( |
12204 *input_name, | 12204 *input_name, |
12205 *input_, | 12205 *input_, |
12206 NONE, | 12206 NONE, |
12207 i::kNonStrictMode)->ToObjectChecked(); | 12207 i::kNonStrictMode)->ToObjectChecked(); |
12208 | 12208 |
12209 MorphThread morph_thread(this); | 12209 MorphThread morph_thread(this); |
12210 morph_thread.Start(); | 12210 morph_thread.Start(); |
12211 v8::Locker::StartPreemption(1); | 12211 v8::Locker::StartPreemption(1); |
12212 LongRunningRegExp(); | 12212 LongRunningRegExp(); |
12213 { | 12213 { |
(...skipping 4930 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
17144 v8::HandleScope scope; | 17144 v8::HandleScope scope; |
17145 LocalContext context; | 17145 LocalContext context; |
17146 | 17146 |
17147 // Compile a try-finally clause where the finally block causes a GC | 17147 // Compile a try-finally clause where the finally block causes a GC |
17148 // while there still is a message pending for external reporting. | 17148 // while there still is a message pending for external reporting. |
17149 TryCatch try_catch; | 17149 TryCatch try_catch; |
17150 try_catch.SetVerbose(true); | 17150 try_catch.SetVerbose(true); |
17151 CompileRun("try { throw new Error(); } finally { gc(); }"); | 17151 CompileRun("try { throw new Error(); } finally { gc(); }"); |
17152 CHECK(try_catch.HasCaught()); | 17152 CHECK(try_catch.HasCaught()); |
17153 } | 17153 } |
OLD | NEW |