Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regression: parsing pointer to pointer missing one '*' (Origin: bugzilla #649103) #4254

Closed
doxygen opened this Issue Jul 2, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@doxygen
Copy link
Owner

doxygen commented Jul 2, 2018

status RESOLVED severity major in component general for ---
Reported in version 1.7.4-SVN on platform Other
Assigned to: Dimitri van Heesch

Original attachment names and IDs:

On 2011-05-01 18:10:26 +0000, Albrecht Schlosser wrote:

Created attachment 186984
Patch to revert regression in parser.

Starting with Release-1.7.1-20100728 (svn -r 738) there is a regression in parsing function return values of type pointer to pointer (or array), e.g.

int const test ( ) { return &array; }

In the resulting documentation (html and pdf) one asterisk ("*") is missing.
This worked well in release 1.7.1, and it is still broken in the latest version (svn -r 765).

Here is a short reproducer:
-- snip --
static int array = 0;
/
* This is wrong :-( /
int * const * test1 ( ) { return &array; }
/
* This is wrong :-( /
int const test1a ( ) { return &array; }
/
* This is wrong :-( /
int * * const test2 ( ) { return &array; }
/
* This is correct. /
int ** const test3 ( ) { return &array; }
/
* This is correct. /
int ** test4 ( ) { return &array; }
/
* This is wrong :-( */
int * * test5 ( ) { return &array; }
-- snip --

In the resulting docs, all functions marked with "This is wrong" are missing the second "*". Only test3 and test4 are correct.

I tracked this down to one particular change in svn r 738. Please see attached patch of file src/scanner.l to revert this change and make it work again.

Please note that I don't want to say that this is a correct fix, because I don't know why this change was done in the first place, but I can clearly see that this fixes the issue above.

Thanks for all your work and your attention to this bug report.

Regards
Albrecht

On 2011-05-01 18:31:29 +0000, Dimitri van Heesch wrote:

Hi Albrecht,

Thanks for the detailed analysis. This change was made to solve bug 623023, but it obviously has unwanted side-effects as you observed. I'll implement a better solution.

On 2011-08-14 14:05:19 +0000, Dimitri van Heesch wrote:

This bug was previously marked ASSIGNED, which means it should be fixed in
doxygen version 1.7.5. Please verify if this is indeed the case. Reopen the
bug if you think it is not fixed and please include any additional information
that you think can be relevant.

On 2011-08-23 13:54:59 +0000, Albrecht Schlosser wrote:

Thanks, the issue is indeed fixed.

@doxygen doxygen closed this Jul 2, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.