Packages icon indicating copy to clipboard operation
Packages copied to clipboard

[C] Missing completions when identifier prefixed by minus (version 4200)

Open wronex opened this issue 4 months ago • 1 comments

Expected behavior

When writing C code such as foo(-BAR) (note the minus sign!) I would expect that BAR is given as a completion suggestion. It is not. It works as expected for foo(+BAR). The minus sign is probably interpreted as part of the name instead of as a separate operator even though syntax highlighting is correct.

Actual behavior

Writing foo(- then pressing Ctrl+Space results in "No available completions".

Steps to reproduce

Use the following code snippet:

#define BAR 0
int foo(int x)
int main()
{
	foo(-);
}

Set Syntax to C.

Place cursor after the minus sign. Invoke auto complete. No completions are found.

Image

wronex avatar Dec 27 '25 19:12 wronex