gtags doesn't index function definitions preceded by a macro resembling a function call
Mihai Olteanu <[email protected]> Fri, 22 Sep 2017 11:36:09 +0300
| Newsgroups | gmane.comp.gnu.global.general |
|---|---|
| Message-ID | <1506069369.2921725.1114598664.76470DD8@webmail.messagingengine.com> |
This is a multi-part message in MIME format.
--===============3713660164438748747==
Content-Transfer-Encoding: 7bit
Content-Type: multipart/alternative; boundary="_----------=_150606936929217250"
This is a multi-part message in MIME format.
--_----------=_150606936929217250
Content-Transfer-Encoding: 7bit
Content-Type: text/plain; charset="utf-8"
Hello,
I'm using gtags 6.5.4 for a C project. Some of the function names are in
the following format:*FUNC(void, MY_CODE) My_Function*(void) {
...
}
where FUNC is a macro defined as
*#define FUNC(rettype, memclass) rettype*
*
*
The global command doesn't find *My_Function *but only a lot of *FUNC*s.So gtags is seeing *FUNC* as a function name and adds that to the list
of tags and not *My_Function*.Is there a way to maybe ignore the FUNC macro or maybe expanding the
macro before searching for tags or some similar methods?
Mihai
--_----------=_150606936929217250
Content-Transfer-Encoding: 7bit
Content-Type: text/html; charset="utf-8"
<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body><div style="font-family:verdana, sans-serif;">Hello,</div>
<div style="font-family:verdana, sans-serif;"><br></div>
<div style="font-family:verdana, sans-serif;">I'm using gtags 6.5.4 for a C project. Some of the function names are in the following format:</div>
<div style="font-family:verdana, sans-serif;"><i>FUNC(void, MY_CODE) My_Function</i>(void) {</div>
<div style="font-family:verdana, sans-serif;">...</div>
<div style="font-family:verdana, sans-serif;">}<br></div>
<div style="font-family:verdana, sans-serif;"><br></div>
<div style="font-family:verdana, sans-serif;">where FUNC is a macro defined as</div>
<div style="font-family:verdana, sans-serif;"><i>#define FUNC(rettype, memclass) rettype</i></div>
<div style="font-family:verdana, sans-serif;"><i><br></i></div>
<div style="font-family:verdana, sans-serif;">The global command doesn't find <i>My_Function </i>but only a lot of <i>FUNC</i>s.</div>
<div style="font-family:verdana, sans-serif;">So gtags is seeing <i>FUNC</i> as a function name and adds that to the list of tags and not <i>My_Function</i>.</div>
<div style="font-family:verdana, sans-serif;">Is there a way to maybe ignore the FUNC macro or maybe expanding the macro before searching for tags or some similar methods?<br></div>
<div style="font-family:verdana, sans-serif;"><br></div>
<div style="font-family:verdana, sans-serif;">Mihai<br></div>
</body>
</html>
--_----------=_150606936929217250--
--===============3713660164438748747==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
Help-global mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/help-global
--===============3713660164438748747==--