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

Side by Side Diff: test/mjsunit/stack-traces.js

Issue 2775503006: [builtins] Improve performance of array.prototype.filter and map (Closed)
Patch Set: Code comments Created 3 years, 7 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
« no previous file with comments | « test/cctest/test-code-stub-assembler.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 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 246 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 throwing(); 257 throwing();
258 reached = true; 258 reached = true;
259 } catch (e) { 259 } catch (e) {
260 assertTrue(e.stack.indexOf(omitted) < 0, omitted); 260 assertTrue(e.stack.indexOf(omitted) < 0, omitted);
261 } finally { 261 } finally {
262 assertFalse(reached); 262 assertFalse(reached);
263 } 263 }
264 } 264 }
265 265
266 266
267 testTrace("testArrayNative", testArrayNative, ["Array.map (native)"]); 267 testTrace("testArrayNative", testArrayNative, ["Array.map"]);
268 testTrace("testNested", testNested, ["at one", "at two", "at three"]); 268 testTrace("testNested", testNested, ["at one", "at two", "at three"]);
269 testTrace("testMethodNameInference", testMethodNameInference, ["at Foo.bar"]); 269 testTrace("testMethodNameInference", testMethodNameInference, ["at Foo.bar"]);
270 testTrace("testImplicitConversion", testImplicitConversion, ["at Nirk.valueOf"]) ; 270 testTrace("testImplicitConversion", testImplicitConversion, ["at Nirk.valueOf"]) ;
271 testTrace("testEval", testEval, ["at Doo (eval at testEval"]); 271 testTrace("testEval", testEval, ["at Doo (eval at testEval"]);
272 testTrace("testNestedEval", testNestedEval, ["eval at Inner (eval at Outer"]); 272 testTrace("testNestedEval", testNestedEval, ["eval at Inner (eval at Outer"]);
273 testTrace("testEvalWithSourceURL", testEvalWithSourceURL, 273 testTrace("testEvalWithSourceURL", testEvalWithSourceURL,
274 [ "at Doo (res://name:1:18)" ]); 274 [ "at Doo (res://name:1:18)" ]);
275 testTrace("testNestedEvalWithSourceURL", testNestedEvalWithSourceURL, 275 testTrace("testNestedEvalWithSourceURL", testNestedEvalWithSourceURL,
276 [" at Inner (res://inner-eval:1:20)", 276 [" at Inner (res://inner-eval:1:20)",
277 " at Outer (res://outer-eval:1:37)"]); 277 " at Outer (res://outer-eval:1:37)"]);
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
430 assertTrue(err.stack.indexOf("prepareStackTrace") != -1); 430 assertTrue(err.stack.indexOf("prepareStackTrace") != -1);
431 431
432 // Check that the callsite constructor throws. 432 // Check that the callsite constructor throws.
433 433
434 Error.prepareStackTrace = (e,s) => s; 434 Error.prepareStackTrace = (e,s) => s;
435 var constructor = new Error().stack[0].constructor; 435 var constructor = new Error().stack[0].constructor;
436 436
437 assertThrows(() => constructor.call()); 437 assertThrows(() => constructor.call());
438 assertThrows(() => constructor.call( 438 assertThrows(() => constructor.call(
439 null, {}, () => undefined, {valueOf() { return 0 }}, false)); 439 null, {}, () => undefined, {valueOf() { return 0 }}, false));
OLDNEW
« no previous file with comments | « test/cctest/test-code-stub-assembler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698