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

There's no such thing as a private Q_PROPERTY (Origin: bugzilla #735462) #5563

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 normal in component general for ---
Reported in version 1.8.8 on platform Other
Assigned to: Dimitri van Heesch

On 2014-08-26 16:29:37 +0000, Kuba Ober wrote:

In Qt, the Q_PROPERTY macro is an empty macro that is used only by moc. The macro declares a public property. It doesn't matter whether it appears in the private, protected, or public sections of the class - the property is always public.

This is a regression from 1.8.7, most likely caused by the fix to bug 734245.

For example, taken from qobject.h from Qt 5:

class Q_CORE_EXPORT QObject
{
Q_OBJECT
Q_PROPERTY(QString objectName READ objectName WRITE setObjectName NOTIFY objectNameChanged)
...
};

This declares a public property, in spite of appearing in a private section of the class. Neither does this macro change the visibility of the succeeding members: its expansion is empty. It's not like the Q_OBJECT macro which does change the visibility of the succeeding members to private.

On 2014-08-30 19:19:15 +0000, Dimitri van Heesch wrote:

Confirmed. Should be fixed in the next GIT update.

On 2014-12-25 16:03:40 +0000, Dimitri van Heesch wrote:

This bug was previously marked ASSIGNED, which means it should be fixed in
doxygen version 1.8.9. 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 (preferrably in the form of a self-contained example).

@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.