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

Side by Side Diff: test/mjsunit/regress/regress-1229.js

Issue 9303032: Fix test case to correctly check expected result. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 10 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 | « no previous file | 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 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 125
126 // Check that %_IsConstructCall returns correct value when inlined 126 // Check that %_IsConstructCall returns correct value when inlined
127 var NON_CONSTRUCT_MARKER = {}; 127 var NON_CONSTRUCT_MARKER = {};
128 var CONSTRUCT_MARKER = {}; 128 var CONSTRUCT_MARKER = {};
129 function baz(x) { 129 function baz(x) {
130 return (!%_IsConstructCall()) ? NON_CONSTRUCT_MARKER : CONSTRUCT_MARKER; 130 return (!%_IsConstructCall()) ? NON_CONSTRUCT_MARKER : CONSTRUCT_MARKER;
131 } 131 }
132 132
133 function bar(x, y, z) { 133 function bar(x, y, z) {
134 var non_construct = baz(0); /* baz should be inlined */ 134 var non_construct = baz(0); /* baz should be inlined */
135 assertEquals(non_construct, NON_CONSTRUCT_MARKER); 135 assertSame(non_construct, NON_CONSTRUCT_MARKER);
136 var non_construct = baz(); /* baz should be inlined */ 136 var non_construct = baz(); /* baz should be inlined */
137 assertEquals(non_construct, NON_CONSTRUCT_MARKER); 137 assertSame(non_construct, NON_CONSTRUCT_MARKER);
138 var non_construct = baz(0, 0); /* baz should be inlined */ 138 var non_construct = baz(0, 0); /* baz should be inlined */
139 assertEquals(non_construct, NON_CONSTRUCT_MARKER); 139 assertSame(non_construct, NON_CONSTRUCT_MARKER);
140 var construct = new baz(0); 140 var construct = new baz(0);
141 assertEquals(construct, CONSTRUCT_MARKER); 141 assertSame(construct, CONSTRUCT_MARKER);
142 } 142 }
143 143
144 invoke(bar, [1, 2, 3]); 144 invoke(bar, [1, 2, 3]);
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698