File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
python/pythonmonkey/builtin_modules Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -42,7 +42,6 @@ class Console {
4242 ignoreErrors = true ;
4343 options = { stdout, stderr, ignoreErrors } ;
4444 }
45-
4645 this . #writeToStdout = options . stdout . write ;
4746 this . #writeToStderr = options . stderr . write ;
4847 }
@@ -55,7 +54,7 @@ class Console {
5554 }
5655
5756 log ( ...args ) {
58- this . writeToStdout ( this . #formatToStr( ...args ) )
57+ this . # writeToStdout( this . #formatToStr( ...args ) )
5958 }
6059
6160 warn ( ...args ) {
@@ -84,8 +83,8 @@ Console.prototype.error = Console.prototype.warn;
8483
8584if ( ! globalThis . console ) {
8685 globalThis . console = new Console (
87- python . stdout . write /* sys.stdout.write */ ,
88- python . stderr . write /* sys.stderr.write */
86+ python . stdout /* sys.stdout */ ,
87+ python . stderr /* sys.stderr */
8988 ) ;
9089}
9190
Original file line number Diff line number Diff line change @@ -14,3 +14,4 @@ if (isCompilableUnit('()=>'))
1414if (!isCompilableUnit('123'))
1515 throw new Error('isCompilableUnit lied about 123');
1616
17+ console.log('done')
You can’t perform that action at this time.
0 commit comments