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

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

Issue 10105026: Version 3.10.3 (Closed) Base URL: http://v8.googlecode.com/svn/trunk/
Patch Set: 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/x64/stub-cache-x64.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 12423 matching lines...) Expand 10 before | Expand all | Expand 10 after
12434 calling_context0.Dispose(); 12434 calling_context0.Dispose();
12435 calling_context1.Dispose(); 12435 calling_context1.Dispose();
12436 calling_context2.Dispose(); 12436 calling_context2.Dispose();
12437 calling_context0.Clear(); 12437 calling_context0.Clear();
12438 calling_context1.Clear(); 12438 calling_context1.Clear();
12439 calling_context2.Clear(); 12439 calling_context2.Clear();
12440 } 12440 }
12441 12441
12442 12442
12443 // Check that a variable declaration with no explicit initialization 12443 // Check that a variable declaration with no explicit initialization
12444 // value does not shadow an existing property in the prototype chain. 12444 // value does shadow an existing property in the prototype chain.
12445 //
12446 // This is consistent with Firefox and Safari.
12447 //
12448 // See http://crbug.com/12548.
12449 THREADED_TEST(InitGlobalVarInProtoChain) { 12445 THREADED_TEST(InitGlobalVarInProtoChain) {
12450 v8::HandleScope scope; 12446 v8::HandleScope scope;
12451 LocalContext context; 12447 LocalContext context;
12452 // Introduce a variable in the prototype chain. 12448 // Introduce a variable in the prototype chain.
12453 CompileRun("__proto__.x = 42"); 12449 CompileRun("__proto__.x = 42");
12454 v8::Handle<v8::Value> result = CompileRun("var x; x"); 12450 v8::Handle<v8::Value> result = CompileRun("var x = 43; x");
12455 CHECK(!result->IsUndefined()); 12451 CHECK(!result->IsUndefined());
12456 CHECK_EQ(42, result->Int32Value()); 12452 CHECK_EQ(43, result->Int32Value());
12457 } 12453 }
12458 12454
12459 12455
12460 // Regression test for issue 398. 12456 // Regression test for issue 398.
12461 // If a function is added to an object, creating a constant function 12457 // If a function is added to an object, creating a constant function
12462 // field, and the result is cloned, replacing the constant function on the 12458 // field, and the result is cloned, replacing the constant function on the
12463 // original should not affect the clone. 12459 // original should not affect the clone.
12464 // See http://code.google.com/p/v8/issues/detail?id=398 12460 // See http://code.google.com/p/v8/issues/detail?id=398
12465 THREADED_TEST(ReplaceConstantFunction) { 12461 THREADED_TEST(ReplaceConstantFunction) {
12466 v8::HandleScope scope; 12462 v8::HandleScope scope;
(...skipping 3938 matching lines...) Expand 10 before | Expand all | Expand 10 after
16405 16401
16406 TEST(SecondaryStubCache) { 16402 TEST(SecondaryStubCache) {
16407 StubCacheHelper(true); 16403 StubCacheHelper(true);
16408 } 16404 }
16409 16405
16410 16406
16411 TEST(PrimaryStubCache) { 16407 TEST(PrimaryStubCache) {
16412 StubCacheHelper(false); 16408 StubCacheHelper(false);
16413 } 16409 }
16414 16410
OLDNEW
« no previous file with comments | « src/x64/stub-cache-x64.cc ('k') | test/cctest/test-decls.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698