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

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

Issue 10163003: Put new global var semantics behind a flag until WebKit tests are cleaned up. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed Michael's comments (and oops, rebased too early). Created 8 years, 8 months 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 | Annotate | Revision Log
« no previous file with comments | « src/runtime.cc ('k') | test/cctest/test-decls.cc » ('j') | 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 12465 matching lines...) Expand 10 before | Expand all | Expand 10 after
12476 calling_context2.Dispose(); 12476 calling_context2.Dispose();
12477 calling_context0.Clear(); 12477 calling_context0.Clear();
12478 calling_context1.Clear(); 12478 calling_context1.Clear();
12479 calling_context2.Clear(); 12479 calling_context2.Clear();
12480 } 12480 }
12481 12481
12482 12482
12483 // Check that a variable declaration with no explicit initialization 12483 // Check that a variable declaration with no explicit initialization
12484 // value does shadow an existing property in the prototype chain. 12484 // value does shadow an existing property in the prototype chain.
12485 THREADED_TEST(InitGlobalVarInProtoChain) { 12485 THREADED_TEST(InitGlobalVarInProtoChain) {
12486 i::FLAG_es52_globals = true;
12486 v8::HandleScope scope; 12487 v8::HandleScope scope;
12487 LocalContext context; 12488 LocalContext context;
12488 // Introduce a variable in the prototype chain. 12489 // Introduce a variable in the prototype chain.
12489 CompileRun("__proto__.x = 42"); 12490 CompileRun("__proto__.x = 42");
12490 v8::Handle<v8::Value> result = CompileRun("var x = 43; x"); 12491 v8::Handle<v8::Value> result = CompileRun("var x = 43; x");
12491 CHECK(!result->IsUndefined()); 12492 CHECK(!result->IsUndefined());
12492 CHECK_EQ(43, result->Int32Value()); 12493 CHECK_EQ(43, result->Int32Value());
12493 } 12494 }
12494 12495
12495 12496
(...skipping 3944 matching lines...) Expand 10 before | Expand all | Expand 10 after
16440 16441
16441 16442
16442 TEST(SecondaryStubCache) { 16443 TEST(SecondaryStubCache) {
16443 StubCacheHelper(true); 16444 StubCacheHelper(true);
16444 } 16445 }
16445 16446
16446 16447
16447 TEST(PrimaryStubCache) { 16448 TEST(PrimaryStubCache) {
16448 StubCacheHelper(false); 16449 StubCacheHelper(false);
16449 } 16450 }
OLDNEW
« no previous file with comments | « src/runtime.cc ('k') | test/cctest/test-decls.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698