-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
structure members are not displayed in suggestions when used in an arithmetic expression after a + or a -. #1905
Comments
Sounds like a bug. I didn't see the problem you describe when I tried it, but we can look into it further. Just checking... did you change the |
I am using the VS code's default. I even checked by installing vscode on xubuntu 16.04.1 live. I installed only the C/C++ extension. Same issue exists. Its strange that it is happening with only + and -. |
I just tested on Linux Mint 18.2 xfce live(It is based on ubuntu 16.04.1) and the issue is not there. Everything is working great here. |
Perhaps the extension is not running at all on your other machine? Can you set |
Pardon me but I don't know what a C/C++ channel is. But when I set the "C_Cpp.loggingLevel" to "6", |
I have a small doubt sir. |
Yeah, I have a C/C++ channel |
If it helps, the below message appeared in c/c++ channel after I set C_Cpp.loggingLevel to its default. $/setTraceNotification |
This sounds the same as #2184 . We had a bug were edits randomly weren't being processed before the completion request. Let us know if this still repros after we ship 0.17.6. |
sure |
Should be fixed with 0.17.6. |
The issue with C files was fixed with https://github.com/microsoft/vscode-cpptools/releases/tag/0.30.0-insiders4 . |
operating system: xubuntu 16.04.1
vscode version: 1.22.2(I am not using insiders build)
C/C++ extension version: 0.16.1
The only extension I have installed currently is this(C/C++).
Example Code Sample:
In the above example after declaring s to be of type student, in the assignment of i after I type "5 - s.", no suggestions are shown. but in the next line on assignment of j, as soon as i type " s. " all members of s are shown. same is the case with assignment to k. But in the assignment to l, as there is a + in the expression before using the structure member no suggestions are shown after typing " s. "
The structure member suggestion is working perfectly fine everywhere else like direct assignment, function parameters, etc except when used in an arithmetic expression after(not just immediately after) a + or a -.
After hitting " s. " in an expression after a + or a - no suggestions are shown automatically. If I hit ctrl+space then the members of the structure s are shown along with all variables and keywords in the code.
If the structure is defined in another header file and #included in this file, the members are not shown after I type " s. " and hit ctrl+enter. To make it clear this is only occurring only if a + or a - is in the arithmetic expression before the use of the structure member.
I have even tried completely uninstalling vscode from the computer.
After the reinstall, it looked like fresh install. I installed only C/C++ extension. But the issue is the same.
linux related settings from c_cpp_properties.json
{
"name": "Linux",
"includePath": [
"${workspaceFolder}",
"/usr/include/c++/5",
"/usr/include/x86_64-linux-gnu/c++/5",
"/usr/include/c++/5/backward",
"/usr/lib/llvm-5.0/lib/clang/5.0.0/include",
"/usr/local/include",
"/usr/include/x86_64-linux-gnu",
"/usr/include"
],
"defines": [],
"intelliSenseMode": "clang-x64",
"browse": {
"path": [
"${workspaceFolder}",
"/usr/include/c++/5",
"/usr/include/x86_64-linux-gnu/c++/5",
"/usr/include/c++/5/backward",
"/usr/lib/llvm-5.0/lib/clang/5.0.0/include",
"/usr/local/include",
"/usr/include/x86_64-linux-gnu",
"/usr/include"
],
"limitSymbolsToIncludedHeaders": true,
"databaseFilename": ""
},
"compilerPath": "/usr/bin/clang",
"cStandard": "c11",
"cppStandard": "c++17"
}
Please help me.
The text was updated successfully, but these errors were encountered: