Strange 写了:你有一个基本问题没搞清,taglist使用的tag是他自己生成的,而不是你在外面生成的tags文件
let Tlist_Ctags_Cmd 只是用来设置命令位置,而不是用来设置参数的
事实上,ctags执行中会自动加入很多参数,结果就是,那些declaration并没有被taglist调用的ctags显示出来
或许问题1的答案应该纠正成这样,taglist不支持这样的功能。
确实是如你说的一样,这个是taglist不支持………………
但是还有一个问题也是让我不甘心的地方,那就是typedef的问题
上面的.h和.cpp文件照旧不变,现在我加一个checktype.h文件,里面自己定义了一个typedef
#ifndef _CHECKTYPE_H__INC
#define _CHECKTYPE_H__INC
#include "xxxx.h" //class check的头文件
typedef check mycheck;
#endif /* ----- #ifndef _CHECKTYPE_H__INC ----- */
然后主cpp:
#include "checktype.h"
int main(){
mycheck a;
a. //这个时候还是不能进行补全,omnicppcomplete告知不知道补全模式,不知道你的是不是这样??
}
我生成的tag文件里面却有这个typedef,如下:
!#ifndef _CHECKTYPE_H__INC
#define _CHECKTYPE_H__INC
typedef check mycheck;
#endif /* ----- #ifndef _CHECKTYPE_H__INC ----- */_TAG_FILE_FORMAT 2 /extended format; --format=1 will not append ;" to lines/
!_TAG_FILE_SORTED 1 /0=unsorted, 1=sorted, 2=foldcase/
!_TAG_PROGRAM_AUTHOR Darren Hiebert /
[email protected]/
!_TAG_PROGRAM_NAME Exuberant Ctags //
!_TAG_PROGRAM_URL
http://ctags.sourceforge.net /official site/
!_TAG_PROGRAM_VERSION 5.6 //
.checkclass.cpp.swp .checkclass.cpp.swp 1;" kind:file line:1 language:C++
.checkclass.h.swp .checkclass.h.swp 1;" kind:file line:1 language:C++
.checktags.swp .checktags.swp 1;" kind:file line:1 language:C++
.checktype.h.swp .checktype.h.swp 1;" kind:file line:1 language:C++
.cout.cpp.swp .cout.cpp.swp 1;" kind:file line:1 language:C++
.main.cpp.swp .main.cpp.swp 1;" kind:file line:1 language:C++
_CHECKCLASS_H__INC checkclass.h 21;" kind:macro line:21 language:C++
_CHECKTYPE_H__INC checktype.h 21;" kind:macro line:21 language:C++
a checkclass.h 29;" kind:member line:29 language:C++ class:hello::check access:public
a main.cpp 23;" kind:local line:23 language:C++
b checkclass.h 30;" kind:member line:30 language:C++ class:hello::check access:public
c checkclass.h 31;" kind:member line:31 language:C++ class:hello::check access:public
check checkclass.cpp 22;" kind:function line:22 language:C++ class:check signature:()
check checkclass.h 23;" kind:class line:23 language:C++ namespace:hello
check checkclass.h 33;" kind:prototype line:33 language:C++ class:hello::check access:public signature:()
check::check checkclass.cpp 22;" kind:function line:22 language:C++ class:check signature:()
check::hehe checkclass.cpp 24;" kind:function line:24 language:C++ class:check signature:()
checkclass.cpp checkclass.cpp 1;" kind:file line:1 language:C++
checkclass.h checkclass.h 1;" kind:file line:1 language:C++
checktags checktags 1;" kind:file line:1 language:C++
checktype.h checktype.h 1;" kind:file line:1 language:C++
cout.cpp cout.cpp 1;" kind:file line:1 language:C++
cppcomplete.tags cppcomplete.tags 1;" kind:file line:1 language:C++
format checktags 1;" kind:variable line:1 language:C++
format cppcomplete.tags 1;" kind:variable line:1 language:C++
format jjtags 1;" kind:variable line:1 language:C++
format xinjjtags 1;" kind:variable line:1 language:C++
haha checkclass.h 35;" kind:prototype line:35 language:C++ class:hello::check access:public signature:()
hehe checkclass.cpp 24;" kind:function line:24 language:C++ class:check signature:()
hehe checkclass.h 34;" kind:prototype line:34 language:C++ class:hello::check access:public signature:()
hello checkclass.h 22;" kind:namespace line:22 language:C++
hello::check checkclass.h 23;" kind:class line:23 language:C++ namespace:hello
hello::check::a checkclass.h 29;" kind:member line:29 language:C++ class:hello::check access:public
hello::check::b checkclass.h 30;" kind:member line:30 language:C++ class:hello::check access:public
hello::check::c checkclass.h 31;" kind:member line:31 language:C++ class:hello::check access:public
hello::check::check checkclass.h 33;" kind:prototype line:33 language:C++ class:hello::check access:public signature:()
hello::check::haha checkclass.h 35;" kind:prototype line:35 language:C++ class:hello::check access:public signature:()
hello::check::hehe checkclass.h 34;" kind:prototype line:34 language:C++ class:hello::check access:public signature:()
hello::check::hoho checkclass.h 36;" kind:prototype line:36 language:C++ class:hello::check access:public signature:()
hello::check::jj checkclass.h 25;" kind:member line:25 language:C++ class:hello::check access:private
hello::check::xiaojj checkclass.h 27;" kind:member line:27 language:C++ class:hello::check access:protected
hoho checkclass.h 36;" kind:prototype line:36 language:C++ class:hello::check access:public signature:()
jj checkclass.h 25;" kind:member line:25 language:C++ class:hello::check access:private
jjtags .checktags.swp 8;" kind:variable line:8 language:C++
jjtags jjtags 1;" kind:file line:1 language:C++
main cout.cpp 26;" kind:function line:26 language:C++ signature:()
main main.cpp 22;" kind:function line:22 language:C++ signature:()
main.cpp main.cpp 1;" kind:file line:1 language:C++
mycheck checktype.h 23;" kind:typedef line:23 language:C++
x cout.cpp 27;" kind:local line:27 language:C++
xiaojj checkclass.h 27;" kind:member line:27 language:C++ class:hello::check access:protected
xinjjtags checktags 10;" kind:variable line:10 language:C++
xinjjtags xinjjtags 1;" kind:file line:1 language:C++
y cout.cpp 27;" kind:local line:27 language:C++
z cout.cpp 27;" kind:local line:27 language:C++