After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 672762 - Wrong callgraph is generated on function pointer assignments
Wrong callgraph is generated on function pointer assignments
Status: RESOLVED OBSOLETE
Product: doxygen
Classification: Other
Component: general
1.8.0
Other All
: Normal major
: ---
Assigned To: Dimitri van Heesch
Dimitri van Heesch
[moved_to_github]
Depends on:
Blocks:
 
 
Reported: 2012-03-24 18:37 UTC by Stéphane Corbé
Modified: 2018-07-30 10:19 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Doxyfile (74.95 KB, application/octet-stream)
2012-03-24 18:37 UTC, Stéphane Corbé
Details

Description Stéphane Corbé 2012-03-24 18:37:08 UTC
Created attachment 210524 [details]
Doxyfile

I saw this bug on Linux and Windows platforms, both in 1.8.0 version.

When a variable is a pointer on function and you assign it to a function, Doxygen see a call to this function.

See the attached Doxyfile and following C code.

I tried to disable the parsing of these assignments with #ifndef and @cond but it doesn't work (at least on Linux)

For me we should see only the main to func3 call.

/** @file */
/** @brief Show callgraph bug on function assignment */

typedef void functype(int);

typedef struct
{
    functype (*m_f1);
    functype (*m_f2);
} s_ess;

s_ess my;


void func1(int a)
{
}


void func2(int b)
{
}

void func3(int b)
{
/** @note of course static analyze cannot guess the called functions */
    my.m_f1(1);
    my.m_f2(2);
}

int main()
{
/** @note my.m_f1 assignment should be ignored */
#ifndef DOXYGEN
    my.m_f1 = func1;
#endif

/** @note my.m_f2 assignment should be ignored */
/** @cond */
    my.m_f2 = func2;
/** @endcond */

/** @note should be the only one in the callgraph */
    func3(3);

    return 0;
}
Comment 1 Stéphane Corbé 2012-03-26 13:16:33 UTC
Seems relative to 618509 and 441228
Comment 2 André Klapper 2018-07-30 10:19:13 UTC
As discussed in https://github.com/doxygen/doxygen/pull/734 , Doxygen has moved its issue tracking to 

   https://github.com/doxygen/doxygen/issues

All Doxygen tickets in GNOME Bugzilla have been migrated to Github. You can subscribe and participate in the new ticket in Github. You can find the corresponding Github ticket by searching for its Bugzilla ID (number) in Github.

Hence I am closing this GNOME Bugzilla ticket.
Please use the corresponding ticket in Github instead. Thanks a lot!