We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5a8e1e8 commit 5fc27ccCopy full SHA for 5fc27cc
src/runtime_debug.js
@@ -17,7 +17,13 @@ function dbg(...args) {
17
// TODO(sbc): Unify with err/out implementation in shell.sh.
18
var fs = require('fs');
19
var utils = require('util');
20
- var stringify = (a) => typeof a == 'object' ? utils.inspect(a) : a;
+ function stringify(a) {
21
+ switch (typeof a) {
22
+ case 'object': return utils.inspect(a);
23
+ case 'undefined': return 'undefined';
24
+ }
25
+ return a;
26
27
fs.writeSync(2, args.map(stringify).join(' ') + '\n');
28
} else
29
#endif
0 commit comments