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

Objective C method / property attribute decoration confuses parsing #9055

Closed
will-work opened this issue Jan 20, 2022 · 8 comments
Closed

Objective C method / property attribute decoration confuses parsing #9055

will-work opened this issue Jan 20, 2022 · 8 comments
Labels
bug enhancement a request to enhance doxygen, not a bug

Comments

@will-work
Copy link

Doxygen 1.9.2 (installed with executable), running on macOS Big Sur, MacBook Pro 2020 M1.

When a property or method declaration in an ObjC h file is decorated with the DEPRECATED_MSG_ATTRIBUTE attribute, Doxygen incorrectly parses the line:

  • a property is interpreted as a method with name 'DEPRECATED_MSG_ATTRIBUTE'
  • a method is misnamed 'DEPRECATED_MSG_ATTRIBUTE'

The expectation is that parsing ignores the attribute decoration entirely.

Example, containing one h file and Doxyfile:

Doxygen_bug.zip

Many thanks for your consideration.

@albert-github albert-github added enhancement a request to enhance doxygen, not a bug bug labels Jan 20, 2022
@albert-github
Copy link
Collaborator

Looks like related to #5940

In the example the deprecated is now implemented by means of the usage of the @deprecated doxygen command, better would be that the DEPRECATED_MSG_ATTRIBUTE is implemented.

In the current situation I think that a workaround is to define DEPRECATED_MSG_ATTRIBUTE(x)= in the PREDEFINED setting.

@will-work
Copy link
Author

Thank you for the pointer @albert-github - the workaround is absolutely acceptable, tested as working.

Many thanks for your quick help.

@albert-github
Copy link
Collaborator

Please don't close this issue, I think the real problem should still be addressed by doxygen i.e. make DEPRECATED_MSG_ATTRIBUTE automatically into a @deprecated entry.

@albert-github albert-github reopened this Jan 20, 2022
@will-work
Copy link
Author

Apologies, that was unintentional, I should have paid attention to the button text.

albert-github added a commit to albert-github/doxygen that referenced this issue Jan 21, 2022
… confuses parsing

Analogous to the Cpp attribute implementation (i.e.`[[...]]`), the Object-C attributes `DEPRECATED_MSG_ATTRIBUTE` and `DEPRECATED_ATTRIBUTE` are ignored.
@albert-github
Copy link
Collaborator

I've just pushed a proposed patch, pull request #9060 that ignores the DEPRECATED_MSG_ATTRIBUTE and DEPRECATED_ATTRIBUTE.

The underlying, complex, problem of making DEPRECATED_MSG_ATTRIBUTE automatically into a @deprecated entry, still has to be addressed, see also #5940

doxygen added a commit that referenced this issue Apr 22, 2022
issue #9055 Objective C method / property attribute decoration confuses parsing
@albert-github albert-github added the fixed but not released Bug is fixed in github, but still needs to make its way to an official release label Apr 23, 2022
@albert-github
Copy link
Collaborator

Code has been integrated in master on GitHub (please don't close the issue as this will be done at the moment of an official release).

@doxygen
Copy link
Owner

doxygen commented May 5, 2022

This issue was previously marked 'fixed but not released',
which means it should be fixed in doxygen version 1.9.4.
Please verify if this is indeed the case. Reopen the
issue if you think it is not fixed and please include any additional information
that you think can be relevant (preferably in the form of a self-contained example).

@doxygen doxygen removed the fixed but not released Bug is fixed in github, but still needs to make its way to an official release label May 5, 2022
@doxygen doxygen closed this as completed May 5, 2022
@will-work
Copy link
Author

will-work commented May 5, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug enhancement a request to enhance doxygen, not a bug
Projects
None yet
Development

No branches or pull requests

3 participants