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

Side by Side Diff: test/cctest/test-heap.cc

Issue 1410073005: Replace FunctionToLocal with CallableToLocal (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 1 month 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
« no previous file with comments | « test/cctest/test-alloc.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 5863 matching lines...) Expand 10 before | Expand all | Expand 10 after
5874 5874
5875 CHECK(utils_has_been_collected); 5875 CHECK(utils_has_been_collected);
5876 } 5876 }
5877 5877
5878 5878
5879 TEST(Regress1878) { 5879 TEST(Regress1878) {
5880 FLAG_allow_natives_syntax = true; 5880 FLAG_allow_natives_syntax = true;
5881 CcTest::InitializeVM(); 5881 CcTest::InitializeVM();
5882 v8::Isolate* isolate = CcTest::isolate(); 5882 v8::Isolate* isolate = CcTest::isolate();
5883 v8::HandleScope scope(isolate); 5883 v8::HandleScope scope(isolate);
5884 v8::Local<v8::Function> constructor = v8::Utils::FunctionToLocal( 5884 v8::Local<v8::Function> constructor = v8::Utils::CallableToLocal(
5885 CcTest::i_isolate()->internal_array_function()); 5885 CcTest::i_isolate()->internal_array_function());
5886 CcTest::global()->Set(v8_str("InternalArray"), constructor); 5886 CcTest::global()->Set(v8_str("InternalArray"), constructor);
5887 5887
5888 v8::TryCatch try_catch(isolate); 5888 v8::TryCatch try_catch(isolate);
5889 5889
5890 CompileRun( 5890 CompileRun(
5891 "var a = Array();" 5891 "var a = Array();"
5892 "for (var i = 0; i < 1000; i++) {" 5892 "for (var i = 0; i < 1000; i++) {"
5893 " var ai = new InternalArray(10000);" 5893 " var ai = new InternalArray(10000);"
5894 " if (%HaveSameMap(ai, a)) throw Error();" 5894 " if (%HaveSameMap(ai, a)) throw Error();"
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after
6280 // The CollectGarbage call above starts sweeper threads. 6280 // The CollectGarbage call above starts sweeper threads.
6281 // The crash will happen if the following two functions 6281 // The crash will happen if the following two functions
6282 // are called before sweeping finishes. 6282 // are called before sweeping finishes.
6283 heap->StartIncrementalMarking(); 6283 heap->StartIncrementalMarking();
6284 heap->FinalizeIncrementalMarkingIfComplete("test"); 6284 heap->FinalizeIncrementalMarkingIfComplete("test");
6285 } 6285 }
6286 6286
6287 6287
6288 } // namespace internal 6288 } // namespace internal
6289 } // namespace v8 6289 } // namespace v8
OLDNEW
« no previous file with comments | « test/cctest/test-alloc.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698