user settings C_Cpp > Default: Compiler Path behavior from setting empty string vs undefined #10795
Labels
bug
fixed
Check the Milestone for the release in which the fix is or will be available.
Language Service
regression
A bug that didn't exist in a previous release
Milestone
Hi, so I noticed a possible bug or unexpected behavior regarding the compiler path settings while trying to repro a user issue on vscode-cmake-tools (3096):
If I remove the default
compilerPath
from my usersettings.json
completely (set undefined),compilerPathIsExplicit
depends only on thecompilerPath
setting inc_cpp_properties.json
. However, if the defaultcompilerPath
in user settings is set to an empty string rather than being undefined,compilerPathIsExplicit
is alwaystrue
.I think this difference in behavior between the default compiler path in user settings being an empty string vs being undefined can be confusing, but I also understand this may be expected behavior. I just wanted to point it out.
However, I think a larger issue is when changing the default user settings via the UI rather than the
settings.json
file, an empty string versus undefined is indistinguishable. Erasing the default compiler path results in the default compiler path to be set to an empty string in the usersettings.json
file rather than undefined. I think this could cause unanticipated problems for users using the UI rather than thesettings.json
file.I'm not sure if this is a bug, but I think it would help if some warning was given in the UI at least. Let me know if you'd like any clarification, thanks!
The text was updated successfully, but these errors were encountered: