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

Unified Diff: test/mjsunit/debugPrint.js

Issue 2626023002: [printing] Improve FixedArray debug printing (Closed)
Patch Set: merge with master Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/objects-printer.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/debugPrint.js
diff --git a/test/mjsunit/debugPrint.js b/test/mjsunit/debugPrint.js
new file mode 100644
index 0000000000000000000000000000000000000000..7c52b17f1fa60608db6a8be107c31ac4c4928807
--- /dev/null
+++ b/test/mjsunit/debugPrint.js
@@ -0,0 +1,29 @@
+// Copyright 2017 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+var largeArray = [];
+largeArray[0xFFFF00] = 123;
+
+var objects = [
+ this,
+ true, false, null, undefined,
+ 1, -1, 1.1, -2.2, -0, 0,
+ Infinity, -Infinity, NaN,
+ "aasdfasdfasdfasdf", "a"+"b",
+ {}, {1:1}, {a:1}, {1:1, 2:2}, Object.create(null),
+ [], [{}, {}], [1, 1, 1], [1.1, 1.1, 1.1, 1.1, 2], largeArray,
+ new Proxy({},{}),
+ new Date(), new String(" a"),
+ new Uint8Array(12),
+ /asdf/, new RegExp(),
+ Object.create, Object, Array,
+ Symbol.iterator,
+ [][Symbol.iterator](),
+ new Map(), new Set(),
+ (new Map()).entries(), (new Set()).entries()
+
+];
+for (var o of objects) %DebugPrint(o);
« no previous file with comments | « src/objects-printer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698