From 369c65635de29af6fd92c835879d70fdac7d2270 Mon Sep 17 00:00:00 2001 From: Dimitri van Heesch Date: Sat, 21 Dec 2019 14:56:26 +0100 Subject: issue 3417: C++: friend template functions shown even with HIDE_FRIEND_COMPOUNDS=yes --- src/config.xml | 2 +- src/memberdef.cpp | 23 ++++++++++++----------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/src/config.xml b/src/config.xml index dfe22e2..bf74fff 100644 --- a/src/config.xml +++ b/src/config.xml @@ -927,7 +927,7 @@ Go to the next section or return to the diff --git a/src/memberdef.cpp b/src/memberdef.cpp index 239d614..99ed224 100644 --- a/src/memberdef.cpp +++ b/src/memberdef.cpp @@ -2145,11 +2145,11 @@ bool MemberDefImpl::isBriefSectionVisible() const // Hide friend (class|struct|union) declarations if HIDE_FRIEND_COMPOUNDS is true bool visibleIfFriendCompound = !(hideFriendCompounds && - isFriend() && + isFriend() /*&& (m_impl->type=="friend class" || m_impl->type=="friend struct" || m_impl->type=="friend union" - ) + )*/ ); // only include members that are non-private unless EXTRACT_PRIVATE is @@ -2719,11 +2719,11 @@ bool MemberDefImpl::isDetailedSectionLinkable() const // hide friend (class|struct|union) member if HIDE_FRIEND_COMPOUNDS // is true bool friendCompoundFilter = !(Config_getBool(HIDE_FRIEND_COMPOUNDS) && - isFriend() && + isFriend() /*&& (m_impl->type=="friend class" || m_impl->type=="friend struct" || m_impl->type=="friend union" - ) + )*/ ); @@ -4187,13 +4187,6 @@ void MemberDefImpl::warnIfUndocumentedParams() const } } -bool MemberDefImpl::isFriendClass() const -{ - return (isFriend() && - (m_impl->type=="friend class" || m_impl->type=="friend struct" || - m_impl->type=="friend union")); -} - bool MemberDefImpl::isDocumentedFriendClass() const { ClassDef *fcd=0; @@ -6135,6 +6128,14 @@ bool MemberDefImpl::isFriendToHide() const return isFriendToHide; } +bool MemberDefImpl::isFriendClass() const +{ + return (isFriend() && + (m_impl->type=="friend class" || m_impl->type=="friend struct" || + m_impl->type=="friend union")); +} + + bool MemberDefImpl::isNotFriend() const { return !(isFriend() && isFriendToHide()); -- cgit v0.12