@@ -1814,8 +1814,8 @@ export class CppProperties {
1814
1814
// Check for path-related squiggles.
1815
1815
let paths : string [ ] = [ ] ;
1816
1816
let compilerPath : string | undefined ;
1817
- for ( const pathArray of [ ( currentConfiguration . browse ? currentConfiguration . browse . path : undefined ) ,
1818
- currentConfiguration . includePath , currentConfiguration . macFrameworkPath ] ) {
1817
+ for ( const pathArray of [ ( currentConfiguration . browse ? currentConfiguration . browse . path : undefined ) ,
1818
+ currentConfiguration . includePath , currentConfiguration . macFrameworkPath ] ) {
1819
1819
if ( pathArray ) {
1820
1820
for ( const curPath of pathArray ) {
1821
1821
paths . push ( `${ curPath } ` ) ;
@@ -1825,7 +1825,7 @@ export class CppProperties {
1825
1825
// Skip the relative forcedInclude files.
1826
1826
if ( currentConfiguration . forcedInclude ) {
1827
1827
for ( const file of currentConfiguration . forcedInclude ) {
1828
- const resolvedFilePath : string = this . resolvePath ( file , isWindows ) ;
1828
+ const resolvedFilePath : string = this . resolvePath ( file ) ;
1829
1829
if ( path . isAbsolute ( resolvedFilePath ) ) {
1830
1830
paths . push ( `${ file } ` ) ;
1831
1831
}
@@ -1843,7 +1843,7 @@ export class CppProperties {
1843
1843
// Resolve and split any environment variables
1844
1844
paths = this . resolveAndSplit ( paths , undefined , this . ExtendedEnvironment ) ;
1845
1845
compilerPath = util . resolveVariables ( compilerPath , this . ExtendedEnvironment ) . trim ( ) ;
1846
- compilerPath = this . resolvePath ( compilerPath , isWindows ) ;
1846
+ compilerPath = this . resolvePath ( compilerPath ) ;
1847
1847
1848
1848
// Get the start/end for properties that are file-only.
1849
1849
const forcedIncludeStart : number = curText . search ( / \s * \" f o r c e d I n c l u d e \" \s * : \s * \[ / ) ;
@@ -1907,7 +1907,7 @@ export class CppProperties {
1907
1907
1908
1908
dotConfigPath = currentConfiguration . dotConfig ;
1909
1909
dotConfigPath = util . resolveVariables ( dotConfigPath , this . ExtendedEnvironment ) . trim ( ) ;
1910
- dotConfigPath = this . resolvePath ( dotConfigPath , isWindows ) ;
1910
+ dotConfigPath = this . resolvePath ( dotConfigPath ) ;
1911
1911
// does not try resolve if the dotConfig property is empty
1912
1912
dotConfigPath = dotConfigPath !== '' ? dotConfigPath : undefined ;
1913
1913
@@ -1946,7 +1946,7 @@ export class CppProperties {
1946
1946
continue ;
1947
1947
}
1948
1948
1949
- let resolvedPath : string = this . resolvePath ( curPath , isWindows ) ;
1949
+ let resolvedPath : string = this . resolvePath ( curPath ) ;
1950
1950
if ( ! resolvedPath ) {
1951
1951
continue ;
1952
1952
}
@@ -1986,15 +1986,15 @@ export class CppProperties {
1986
1986
let message : string ;
1987
1987
if ( ! pathExists ) {
1988
1988
if ( curOffset >= forcedIncludeStart && curOffset <= forcedeIncludeEnd
1989
- && ! path . isAbsolute ( resolvedPath ) ) {
1989
+ && ! path . isAbsolute ( resolvedPath ) ) {
1990
1990
continue ; // Skip the error, because it could be resolved recursively.
1991
1991
}
1992
1992
message = localize ( 'cannot.find2' , "Cannot find \"{0}\"." , resolvedPath ) ;
1993
1993
newSquiggleMetrics . PathNonExistent ++ ;
1994
1994
} else {
1995
1995
// Check for file versus path mismatches.
1996
1996
if ( ( curOffset >= forcedIncludeStart && curOffset <= forcedeIncludeEnd ) ||
1997
- ( curOffset >= compileCommandsStart && curOffset <= compileCommandsEnd ) ) {
1997
+ ( curOffset >= compileCommandsStart && curOffset <= compileCommandsEnd ) ) {
1998
1998
if ( util . checkFileExistsSync ( resolvedPath ) ) {
1999
1999
continue ;
2000
2000
}
@@ -2018,7 +2018,6 @@ export class CppProperties {
2018
2018
// TODO: This never matches. https://github.com/microsoft/vscode-cpptools/issues/9140
2019
2019
const envMatches : string [ ] | null = envText . match ( pattern ) ;
2020
2020
if ( envMatches ) {
2021
-
2022
2021
let curOffset : number = 0 ;
2023
2022
let endOffset : number = 0 ;
2024
2023
for ( const curMatch of envMatches ) {
@@ -2066,7 +2065,6 @@ export class CppProperties {
2066
2065
telemetry . logLanguageServerEvent ( "ConfigSquiggles" , undefined , changedSquiggleMetrics ) ;
2067
2066
}
2068
2067
this . prevSquiggleMetrics . set ( currentConfiguration . name , newSquiggleMetrics ) ;
2069
-
2070
2068
}
2071
2069
2072
2070
private updateToVersion2 ( ) : void {
0 commit comments