File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -175,9 +175,11 @@ FAILED: src/test.cmj src/test.cmi
175
175
let ret : { [ key : string ] : t . Diagnostic [ ] } = { }
176
176
res . forEach ( diagnosisLines => {
177
177
let [ fileAndLocation , ...diagnosisMessage ] = diagnosisLines
178
- let lastSpace = fileAndLocation . lastIndexOf ( ' ' )
179
- let file = fileAndLocation . substring ( 2 , lastSpace )
180
- let location = fileAndLocation . substring ( lastSpace )
178
+ let locationSeparatorV840 = fileAndLocation . lastIndexOf ( ':' )
179
+ let locationSeparatorV830 = fileAndLocation . lastIndexOf ( ' ' )
180
+ let locationSeparator = locationSeparatorV830 >= 0 ? locationSeparatorV840 : locationSeparatorV830
181
+ let file = fileAndLocation . substring ( 2 , locationSeparator )
182
+ let location = fileAndLocation . substring ( locationSeparator )
181
183
if ( ret [ file ] == null ) {
182
184
ret [ file ] = [ ]
183
185
}
You can’t perform that action at this time.
0 commit comments