Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign
Clang command line support for codecompletion
ollydbg:
I just find a useful file (the file can be enable codecompletion for emace)
http://stackoverflow.com/questions/2487931/llvm-c-ide-for-windows
and
https://llvm.org/svn/llvm-project/cfe/trunk/utils/clang-completion-mode.el
http://mike.struct.cn/blogs/entry/15/
I have never used emace.
Can some emace guys give some comments on this?
So that we can use the same command line?
oBFusCATed:
ollydbg: if you plan to integrate clang, please, don't do it with creating another process and communicating with some IPC mechanism.
The proper way is to link directly to clangs libs. It will save you many problems.
ollydbg:
--- Quote from: oBFusCATed on October 25, 2010, 10:11:50 am ---ollydbg: if you plan to integrate clang, please, don't do it with creating another process and communicating with some IPC mechanism.
The proper way is to link directly to clangs libs. It will save you many problems.
--- End quote ---
thanks for the hint.
currently, I'm checking Clang's features (command line mode) listed in
Examples of using Clang section of http://clang.llvm.org/get_started.html
Tested by this package
http://llvm.org/releases/2.8/llvm-gcc4.2-2.8-x86-mingw32.tar.bz2
It seems I can't get the result from
--- Code: ---$ clang -cc1 ~/t.c -ast-print
--- End code ---
I have the error like:
--- Code: ---F:\cb\test_code\test_clang>llvm-c++ main.cpp
llvm-c++: CreateProcess: No such file or directory
F:\cb\test_code\test_clang>llvm-c++ main.cpp -E
# 1 "main.cpp"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "main.cpp"
int main()
{
}
F:\cb\test_code\test_clang>llvm-c++ main.cpp -cc1 -ast-print
llvm-c++: unrecognized option '-cc1'
cc1plus.exe: error: unrecognized command line option "-ast-print"
F:\cb\test_code\test_clang>llvm-c++ -cc1 main.cpp -ast-print
llvm-c++: unrecognized option '-cc1'
cc1plus.exe: error: unrecognized command line option "-ast-print"
--- End code ---
So, I have to firstly figure it out. :D
eranif:
You might find this useful:
http://codelite.svn.sourceforge.net/viewvc/codelite/trunk/LiteEditor/clang_code_completion.h?revision=4207&view=markup
http://codelite.svn.sourceforge.net/viewvc/codelite/trunk/LiteEditor/clang_code_completion.cpp?revision=4207&view=markup
It is working (currently disabled)
Although it uses the command line invocation of clang executable.
Note that clang itself provides a lib named 'libIndex' to perform what I am doing in the linked code. However, they too are invoking clang from the command line.
Eran
ollydbg:
thanks eranif.
I will look into your links.
btw: did you know some Clang binaries which works under windows.
http://llvm.org/releases/2.8/llvm-gcc4.2-2.8-x86-mingw32.tar.bz2 seems is not a full package
thanks.
Navigation
[0] Message Index
[#] Next page
Go to full version