clang_complete icon indicating copy to clipboard operation
clang_complete copied to clipboard

How can I let clang_complete complete GNU C extensions' types or functions

Open iosmanthus opened this issue 9 years ago • 3 comments

After I knew Clang is compatible with gcc, I realized I could use gnu c extensions' types or functions in clang. But clang_complete only completes the macros not the functions, types and the key word... So .....

iosmanthus avatar May 11 '16 05:05 iosmanthus

It might need explicit argument like -std=gnu++11, I'm not sure whether clang defaults to GNU dialect by default.

xaizek avatar May 11 '16 08:05 xaizek

can't work .... By the way,Clang dialect includes GNU dialect(like label in the left window) and clang dialects(except macros) don't show in the list.. screenshot from 2016-05-11 18-26-04

iosmanthus avatar May 11 '16 10:05 iosmanthus

Hard to say whether it should work and something is wrong with the plugin or there is just no such completion. In clang file I found there is only one check for GNUMode (e.g. gnu++11) that enables completion of typedef keyword, that file consists of 7500 lines and seems to perform a lot of work related to completion, so I'm not sure there is no other code for completion, but it makes me doubt whether this kind of completion should work (i.e. whether it completes builtins at all).

xaizek avatar May 11 '16 16:05 xaizek