Skip to content

Commit

Permalink
Fix System.out.println/printf not defined problem.
Browse files Browse the repository at this point in the history
  • Loading branch information
wangzhengbo2 committed Apr 13, 2020
1 parent 0ae7a4a commit 090eaa9
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/js/common.js
Expand Up @@ -92,6 +92,15 @@ System.arraycopy = function (src, srcPos, dest, destPos, length) {
dest[destPos++] = src[srcPos++];
};

System.out = {};
System.out.println = function (message) {
console.log(message);
}

System.out.printf = function () {
console.log.apply(console, arguments);
}


var Util = {};
Util.SQRT2 = 1.41421356237309504880;
Expand Down

0 comments on commit 090eaa9

Please sign in to comment.