emscripten: Use argument list for Module.print

This commit is contained in:
Rob Loach 2018-01-15 10:06:06 -05:00 committed by GitHub
parent 2f6297838e
commit cb3ab8b12e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -110,14 +110,15 @@
{
return function(text)
{
console.log(text)
text = Array.prototype.slice.call(arguments).join(' ');
console.log(text);
};
})(),
printErr: function(text)
{
var errArgs = Array.prototype.slice.call(arguments).join(' ');
console.error(errArgs)
console.error(errArgs);
},
canvas: document.getElementById('canvas'),