From bd9a13b370c65f889da1d42852d8107915edd977 Mon Sep 17 00:00:00 2001 From: Topi Reinio Date: Tue, 17 Mar 2020 20:50:04 +0100 Subject: [PATCH] Doc: Fix \fn command for qScopeGuard(F &&f) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit and tag it in the header file to ensure the documentation is matched. Change-Id: Id1e7cd395ca0ec337845da9a207bfbf95db01064 Reviewed-by: Paul Wicking Reviewed-by: MÃ¥rten Nordheim --- src/corelib/tools/qscopeguard.h | 1 + src/corelib/tools/qscopeguard.qdoc | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/corelib/tools/qscopeguard.h b/src/corelib/tools/qscopeguard.h index 6a5bc6cc61..d288fd63fc 100644 --- a/src/corelib/tools/qscopeguard.h +++ b/src/corelib/tools/qscopeguard.h @@ -96,6 +96,7 @@ private: template QScopeGuard(F(&)()) -> QScopeGuard; #endif +//! [qScopeGuard] template #if __has_cpp_attribute(nodiscard) Q_REQUIRED_RESULT diff --git a/src/corelib/tools/qscopeguard.qdoc b/src/corelib/tools/qscopeguard.qdoc index 572934d890..b36299d296 100644 --- a/src/corelib/tools/qscopeguard.qdoc +++ b/src/corelib/tools/qscopeguard.qdoc @@ -69,7 +69,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn template const QScopeGuard qScopeGuard(F f) + \fn [qScopeGuard] template QScopeGuard::type> qScopeGuard(F &&f) \inmodule QtCore \relates QScopeGuard \brief The qScopeGuard function can be used to call a function at the end