@@ -100,11 +100,11 @@ const {
100
100
const { BuiltinModule } = require ( 'internal/bootstrap/loaders' ) ;
101
101
const {
102
102
makeRequireFunction,
103
- addBuiltinLibsToObject
103
+ addBuiltinLibsToObject,
104
104
} = require ( 'internal/modules/cjs/helpers' ) ;
105
105
const {
106
106
isIdentifierStart,
107
- isIdentifierChar
107
+ isIdentifierChar,
108
108
} = require ( 'internal/deps/acorn/acorn/dist/acorn' ) ;
109
109
const {
110
110
decorateErrorStack,
@@ -119,7 +119,7 @@ const path = require('path');
119
119
const fs = require ( 'fs' ) ;
120
120
const { Interface } = require ( 'readline' ) ;
121
121
const {
122
- commonPrefix
122
+ commonPrefix,
123
123
} = require ( 'internal/readline/utils' ) ;
124
124
const { Console } = require ( 'console' ) ;
125
125
const CJSModule = require ( 'internal/modules/cjs/loader' ) . Module ;
@@ -174,7 +174,7 @@ const {
174
174
} = internalBinding ( 'util' ) ;
175
175
const {
176
176
startSigintWatchdog,
177
- stopSigintWatchdog
177
+ stopSigintWatchdog,
178
178
} = internalBinding ( 'contextify' ) ;
179
179
180
180
const history = require ( 'internal/repl/history' ) ;
@@ -298,7 +298,7 @@ function REPLServer(prompt,
298
298
'DEP0141' ) :
299
299
( val ) => this . input = val ,
300
300
enumerable : false ,
301
- configurable : true
301
+ configurable : true ,
302
302
} ) ;
303
303
ObjectDefineProperty ( this , 'outputStream' , {
304
304
__proto__ : null ,
@@ -315,7 +315,7 @@ function REPLServer(prompt,
315
315
'DEP0141' ) :
316
316
( val ) => this . output = val ,
317
317
enumerable : false ,
318
- configurable : true
318
+ configurable : true ,
319
319
} ) ;
320
320
321
321
this . allowBlockingCompletions = ! ! options . allowBlockingCompletions ;
@@ -464,7 +464,7 @@ function REPLServer(prompt,
464
464
importModuleDynamically : ( specifier , _ , importAssertions ) => {
465
465
return asyncESM . esmLoader . import ( specifier , parentURL ,
466
466
importAssertions ) ;
467
- }
467
+ } ,
468
468
} ) ;
469
469
} catch ( fallbackError ) {
470
470
if ( isRecoverableError ( fallbackError , fallbackCode ) ) {
@@ -508,7 +508,7 @@ function REPLServer(prompt,
508
508
importModuleDynamically : ( specifier , _ , importAssertions ) => {
509
509
return asyncESM . esmLoader . import ( specifier , parentURL ,
510
510
importAssertions ) ;
511
- }
511
+ } ,
512
512
} ) ;
513
513
} catch ( e ) {
514
514
debug ( 'parse error %j' , code , e ) ;
@@ -565,7 +565,7 @@ function REPLServer(prompt,
565
565
try {
566
566
const scriptOptions = {
567
567
displayErrors : false ,
568
- breakOnSigint : self . breakEvalOnSigint
568
+ breakOnSigint : self . breakEvalOnSigint ,
569
569
} ;
570
570
571
571
if ( self . useGlobal ) {
@@ -769,7 +769,7 @@ function REPLServer(prompt,
769
769
completer : options . completer || completer ,
770
770
terminal : options . terminal ,
771
771
historySize : options . historySize ,
772
- prompt
772
+ prompt,
773
773
} ] ) ;
774
774
775
775
self . resetContext ( ) ;
@@ -795,7 +795,7 @@ function REPLServer(prompt,
795
795
return ObjectAssign ( writer . options , options ) ;
796
796
} ,
797
797
enumerable : true ,
798
- configurable : true
798
+ configurable : true ,
799
799
} ) ;
800
800
}
801
801
}
@@ -969,7 +969,7 @@ function REPLServer(prompt,
969
969
970
970
const {
971
971
clearPreview,
972
- showPreview
972
+ showPreview,
973
973
} = setupPreview (
974
974
this ,
975
975
kContextId ,
@@ -1099,7 +1099,7 @@ REPLServer.prototype.createContext = function() {
1099
1099
__proto__ : null ,
1100
1100
configurable : true ,
1101
1101
writable : true ,
1102
- value : _console
1102
+ value : _console ,
1103
1103
} ) ;
1104
1104
}
1105
1105
@@ -1110,13 +1110,13 @@ REPLServer.prototype.createContext = function() {
1110
1110
__proto__ : null ,
1111
1111
configurable : true ,
1112
1112
writable : true ,
1113
- value : replModule
1113
+ value : replModule ,
1114
1114
} ) ;
1115
1115
ObjectDefineProperty ( context , 'require' , {
1116
1116
__proto__ : null ,
1117
1117
configurable : true ,
1118
1118
writable : true ,
1119
- value : makeRequireFunction ( replModule )
1119
+ value : makeRequireFunction ( replModule ) ,
1120
1120
} ) ;
1121
1121
1122
1122
addBuiltinLibsToObject ( context , '<REPL>' ) ;
@@ -1142,7 +1142,7 @@ REPLServer.prototype.resetContext = function() {
1142
1142
this . underscoreAssigned = true ;
1143
1143
this . output . write ( 'Expression assignment to _ now disabled.\n' ) ;
1144
1144
}
1145
- }
1145
+ } ,
1146
1146
} ) ;
1147
1147
1148
1148
ObjectDefineProperty ( this . context , '_error' , {
@@ -1156,7 +1156,7 @@ REPLServer.prototype.resetContext = function() {
1156
1156
this . output . write (
1157
1157
'Expression assignment to _error now disabled.\n' ) ;
1158
1158
}
1159
- }
1159
+ } ,
1160
1160
} ) ;
1161
1161
1162
1162
// Allow REPL extensions to extend the new context
@@ -1242,7 +1242,7 @@ function getGlobalLexicalScopeNames(contextId) {
1242
1242
return sendInspectorCommand ( ( session ) => {
1243
1243
let names = [ ] ;
1244
1244
session . post ( 'Runtime.globalLexicalScopeNames' , {
1245
- executionContextId : contextId
1245
+ executionContextId : contextId ,
1246
1246
} , ( error , result ) => {
1247
1247
if ( ! error ) names = result . names ;
1248
1248
} ) ;
@@ -1666,7 +1666,7 @@ function _memory(cmd) {
1666
1666
// scope will not work for this function.
1667
1667
ArrayPrototypePush ( self . lines . level , {
1668
1668
line : self . lines . length - 1 ,
1669
- depth : depth
1669
+ depth : depth ,
1670
1670
} ) ;
1671
1671
} else if ( depth < 0 ) {
1672
1672
// Going... up.
@@ -1716,7 +1716,7 @@ function defineDefaultCommands(repl) {
1716
1716
action : function ( ) {
1717
1717
this . clearBufferedCommand ( ) ;
1718
1718
this . displayPrompt ( ) ;
1719
- }
1719
+ } ,
1720
1720
} ) ;
1721
1721
1722
1722
let clearMessage ;
@@ -1734,14 +1734,14 @@ function defineDefaultCommands(repl) {
1734
1734
this . resetContext ( ) ;
1735
1735
}
1736
1736
this . displayPrompt ( ) ;
1737
- }
1737
+ } ,
1738
1738
} ) ;
1739
1739
1740
1740
repl . defineCommand ( 'exit' , {
1741
1741
help : 'Exit the REPL' ,
1742
1742
action : function ( ) {
1743
1743
this . close ( ) ;
1744
- }
1744
+ } ,
1745
1745
} ) ;
1746
1746
1747
1747
repl . defineCommand ( 'help' , {
@@ -1761,7 +1761,7 @@ function defineDefaultCommands(repl) {
1761
1761
this . output . write ( '\nPress Ctrl+C to abort current expression, ' +
1762
1762
'Ctrl+D to exit the REPL\n' ) ;
1763
1763
this . displayPrompt ( ) ;
1764
- }
1764
+ } ,
1765
1765
} ) ;
1766
1766
1767
1767
repl . defineCommand ( 'save' , {
@@ -1774,7 +1774,7 @@ function defineDefaultCommands(repl) {
1774
1774
this . output . write ( `Failed to save: ${ file } \n` ) ;
1775
1775
}
1776
1776
this . displayPrompt ( ) ;
1777
- }
1777
+ } ,
1778
1778
} ) ;
1779
1779
1780
1780
repl . defineCommand ( 'load' , {
@@ -1797,7 +1797,7 @@ function defineDefaultCommands(repl) {
1797
1797
this . output . write ( `Failed to load: ${ file } \n` ) ;
1798
1798
}
1799
1799
this . displayPrompt ( ) ;
1800
- }
1800
+ } ,
1801
1801
} ) ;
1802
1802
if ( repl . terminal ) {
1803
1803
repl . defineCommand ( 'editor' , {
@@ -1806,7 +1806,7 @@ function defineDefaultCommands(repl) {
1806
1806
_turnOnEditorMode ( this ) ;
1807
1807
this . output . write (
1808
1808
'// Entering editor mode (Ctrl+D to finish, Ctrl+C to cancel)\n' ) ;
1809
- }
1809
+ } ,
1810
1810
} ) ;
1811
1811
}
1812
1812
}
@@ -1823,15 +1823,15 @@ module.exports = {
1823
1823
REPLServer,
1824
1824
REPL_MODE_SLOPPY ,
1825
1825
REPL_MODE_STRICT ,
1826
- Recoverable
1826
+ Recoverable,
1827
1827
} ;
1828
1828
1829
1829
ObjectDefineProperty ( module . exports , 'builtinModules' , {
1830
1830
__proto__ : null ,
1831
1831
get : ( ) => _builtinLibs ,
1832
1832
set : ( val ) => _builtinLibs = val ,
1833
1833
enumerable : true ,
1834
- configurable : true
1834
+ configurable : true ,
1835
1835
} ) ;
1836
1836
1837
1837
ObjectDefineProperty ( module . exports , '_builtinLibs' , {
@@ -1847,5 +1847,5 @@ ObjectDefineProperty(module.exports, '_builtinLibs', {
1847
1847
'DEP0142' ,
1848
1848
) : ( val ) => _builtinLibs = val ,
1849
1849
enumerable : false ,
1850
- configurable : true
1850
+ configurable : true ,
1851
1851
} ) ;
0 commit comments