When I run cscope-15.7a on the following file (attached):
1 typedef struct
2 {
3 int x;
4 } int_t;
5
6 typedef int (*my_func_t) (
7 int_t x,
8 int_t y,
9 char mode
10 );
and try to find global definition:
Find this global definition: int_t
I get the following result:
Global definition: int_t
File Line
0 my.h 4 } int_t;
1 my.h 7 int_t x,
2 my.h 8 int_t y,
I believe that the correct result should be:
File Line
0 my.h 4 } int_t;
Thanks!
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
Simple example
This is a well-known issue, and largely unrelated to the typedef. The problem is, and always has been, about function pointers. They throw off cscope's parser by having extra parentheses in an awkward place. Typedefed function pointers work marginally better than directly declared ones, but really only marginally.