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

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

Issue 151191: Make global variable initialization consistent with Firefox and Safari... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 5 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 | « test/cctest/test-api.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 2007-2008 the V8 project authors. All rights reserved. 1 // Copyright 2007-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 516 matching lines...) Expand 10 before | Expand all | Expand 10 after
527 { ExistsInPrototypeContext context; 527 { ExistsInPrototypeContext context;
528 context.Check("this.x = 87; this.x", 528 context.Check("this.x = 87; this.x",
529 0, 529 0,
530 0, 530 0,
531 0, 531 0,
532 EXPECT_RESULT, Number::New(87)); 532 EXPECT_RESULT, Number::New(87));
533 } 533 }
534 534
535 { ExistsInPrototypeContext context; 535 { ExistsInPrototypeContext context;
536 context.Check("var x; x", 536 context.Check("var x; x",
537 0, 537 1, // get
538 0, 538 0,
539 1, // declaration 539 1, // declaration
540 EXPECT_RESULT, Undefined()); 540 EXPECT_EXCEPTION);
541 } 541 }
542 542
543 { ExistsInPrototypeContext context; 543 { ExistsInPrototypeContext context;
544 context.Check("var x = 0; x", 544 context.Check("var x = 0; x",
545 0, 545 0,
546 0, 546 0,
547 1, // declaration 547 1, // declaration
548 EXPECT_RESULT, Number::New(0)); 548 EXPECT_RESULT, Number::New(0));
549 } 549 }
550 550
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
585 HandleScope scope; 585 HandleScope scope;
586 586
587 { AbsentInPrototypeContext context; 587 { AbsentInPrototypeContext context;
588 context.Check("if (false) { var x = 0; }; x", 588 context.Check("if (false) { var x = 0; }; x",
589 0, 589 0,
590 0, 590 0,
591 1, // declaration 591 1, // declaration
592 EXPECT_RESULT, Undefined()); 592 EXPECT_RESULT, Undefined());
593 } 593 }
594 } 594 }
OLDNEW
« no previous file with comments | « test/cctest/test-api.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698