@@ -129,10 +129,10 @@ export class Warp10DebugSession extends LoggingDebugSession {
129129 this . inlineDecoration = window . createTextEditorDecorationType ( { before : { color : "red" , contentText : "⯆" } } ) ;
130130 window . activeTextEditor . setDecorations ( this . inlineDecoration , [
131131 new Range (
132- exception . info . line - 1 ,
133- exception . info . colStart - 1 ,
134- exception . info . line - 1 ,
135- exception . info . colStart - 1
132+ Math . max ( exception . info . line - 1 , 0 ) ,
133+ Math . max ( exception . info . colStart - 1 , 0 ) ,
134+ Math . max ( exception . info . line - 1 , 0 ) ,
135+ Math . max ( exception . info . colStart - 1 , 0 )
136136 )
137137 ] ) ;
138138 if ( window . activeTextEditor ) {
@@ -142,10 +142,10 @@ export class Warp10DebugSession extends LoggingDebugSession {
142142 code : '' ,
143143 message : exception . e ,
144144 range : new Range (
145- exception . info . line - 1 ,
146- exception . info . colStart - 1 ,
147- exception . info . line - 1 ,
148- exception . info . colEnd
145+ Math . max ( exception . info . line - 1 , 0 ) ,
146+ Math . max ( exception . info . colStart - 1 , 0 ) ,
147+ Math . max ( exception . info . line - 1 , 0 ) ,
148+ Math . max ( exception . info . colEnd , 0 )
149149 ) ,
150150 severity : DiagnosticSeverity . Error ,
151151 source : window . activeTextEditor . document . uri . toString ( ) ,
@@ -166,10 +166,10 @@ export class Warp10DebugSession extends LoggingDebugSession {
166166 this . inlineDecoration = window . createTextEditorDecorationType ( { before : { color : "red" , contentText : "⯆" } } ) ;
167167 window . activeTextEditor . setDecorations ( this . inlineDecoration , [
168168 new Range (
169- info . line - 1 ,
170- info . colStart - 1 ,
171- info . line - 1 ,
172- info . colStart - 1
169+ Math . max ( info . line - 1 , 0 ) ,
170+ Math . max ( info . colStart - 1 , 0 ) ,
171+ Math . max ( info . line - 1 , 0 ) ,
172+ Math . max ( info . colStart - 1 , 0 )
173173 )
174174 ] ) ;
175175 }
0 commit comments