@@ -160,7 +160,7 @@ function Client() {
160160 protocol . execute ( d ) ;
161161 } ) ;
162162
163- protocol . onResponse = this . _onResponse . bind ( this ) ;
163+ protocol . onResponse = ( res ) => this . _onResponse ( res ) ;
164164}
165165inherits ( Client , net . Socket ) ;
166166exports . Client = Client ;
@@ -735,7 +735,7 @@ function Interface(stdin, stdout, args) {
735735 prompt : 'debug> ' ,
736736 input : this . stdin ,
737737 output : this . stdout ,
738- eval : this . controlEval . bind ( this ) ,
738+ eval : ( code , ctx , file , cb ) => this . controlEval ( code , ctx , file , cb ) ,
739739 useGlobal : false ,
740740 ignoreUndefined : true
741741 } ;
@@ -766,7 +766,7 @@ function Interface(stdin, stdout, args) {
766766 } ) ;
767767
768768 // Handle all possible exits
769- process . on ( 'exit' , this . killChild . bind ( this ) ) ;
769+ process . on ( 'exit' , ( ) => this . killChild ( ) ) ;
770770 process . once ( 'SIGTERM' , process . exit . bind ( process , 0 ) ) ;
771771 process . once ( 'SIGHUP' , process . exit . bind ( process , 0 ) ) ;
772772
@@ -1588,7 +1588,8 @@ Interface.prototype.repl = function() {
15881588 this . repl . on ( 'exit' , exitDebugRepl ) ;
15891589
15901590 // Set new
1591- this . repl . eval = this . debugEval . bind ( this ) ;
1591+ this . repl . eval = ( code , ctx , file , cb ) =>
1592+ this . debugEval ( code , ctx , file , cb ) ;
15921593 this . repl . context = { } ;
15931594
15941595 // Swap history
@@ -1603,7 +1604,8 @@ Interface.prototype.repl = function() {
16031604// Exit debug repl
16041605Interface . prototype . exitRepl = function ( ) {
16051606 // Restore eval
1606- this . repl . eval = this . controlEval . bind ( this ) ;
1607+ this . repl . eval = ( code , ctx , file , cb ) =>
1608+ this . controlEval ( code , ctx , file , cb ) ;
16071609
16081610 // Swap history
16091611 this . history . debug = this . repl . rli . history ;
@@ -1690,8 +1692,8 @@ Interface.prototype.trySpawn = function(cb) {
16901692 // pipe stream into debugger
16911693 this . child = spawn ( process . execPath , childArgs ) ;
16921694
1693- this . child . stdout . on ( 'data' , this . childPrint . bind ( this ) ) ;
1694- this . child . stderr . on ( 'data' , this . childPrint . bind ( this ) ) ;
1695+ this . child . stdout . on ( 'data' , ( text ) => this . childPrint ( text ) ) ;
1696+ this . child . stderr . on ( 'data' , ( text ) => this . childPrint ( text ) ) ;
16951697 }
16961698
16971699 this . pause ( ) ;
0 commit comments