You are not logged in.
vim-ctype
Plugin uses clang facility to determine type of instance (type of variable, function, etc.) under cursor.
Main part is clang-gettype utility is written on C. It based on client-server architecture using unix domain sockets. Client accepts source code file and location (line number and column) of instance as command line arguments, send request to server and outputs type of specified instance. Vimscript code wraps this functional. By default it shows instance type in Vim command line, but this behavior can be changed. Last received instance type always is available in g:ctype_type variable, so you can direct output to Vim statusline:
set statusline += %{g:ctype_type}
let g:ctype_updatestl = 1
Last edited by Kirill Bugaev (2019-05-31 07:44:03)
Offline
Comrades have fixed bugs in libclang. So now plugin can show C code types on fly without generating AST file. Compilation Database support added. If not all types are displayed, then db is needed (can be created easy with CMake). Unfortunately, for C++ code AST file still required. But I hope comrades will fix it soon or later.
Offline