diff --git a/src/Parser.ts b/src/Parser.ts index 01821a5a03..5938e2ead9 100644 --- a/src/Parser.ts +++ b/src/Parser.ts @@ -471,6 +471,8 @@ export class Parser { case ParserState.DCS: if (ch === C0.ESC || ch === C0.BEL) { if (ch === C0.ESC) this._position++; + let pt; + let valid: boolean; switch (this._terminal.prefix) { // User-Defined Keys (DECUDK). @@ -480,8 +482,8 @@ export class Parser { // Request Status String (DECRQSS). // test: echo -e '\eP$q"p\e\\' case '$q': - let pt = this._terminal.currentParam - , valid = false; + pt = this._terminal.currentParam; + valid = false; switch (pt) { // DECSCA @@ -526,9 +528,8 @@ export class Parser { // This can cause a small glitch in vim. // test: echo -ne '\eP+q6b64\e\\' case '+q': - // TODO: Don't declare pt twice - /*let*/ pt = this._terminal.currentParam - , valid = false; + pt = this._terminal.currentParam; + valid = false; this._terminal.send(C0.ESC + 'P' + +valid + '+r' + pt + C0.ESC + '\\'); break;