From 64d976ef1a8ed86f7ae25b632e7682d19740f317 Mon Sep 17 00:00:00 2001 From: Martin Smith Date: Wed, 13 Sep 2017 13:27:51 +0200 Subject: Add template text to \fn commands in QScopedPointer The \fn commands were not recognized by clang-qdoc because the template stuff was missing from the \fn commands. This update adds the correct template text and parameters. Change-Id: If45465880933174f1481a8be292474be191cfd45 Reviewed-by: Martin Smith --- src/corelib/tools/qscopedpointer.cpp | 48 +++++++++++++++++++----------------- 1 file changed, 26 insertions(+), 22 deletions(-) (limited to 'src') diff --git a/src/corelib/tools/qscopedpointer.cpp b/src/corelib/tools/qscopedpointer.cpp index f3a4f0ca1f..605758dcc3 100644 --- a/src/corelib/tools/qscopedpointer.cpp +++ b/src/corelib/tools/qscopedpointer.cpp @@ -126,34 +126,34 @@ QT_BEGIN_NAMESPACE */ /*! - \fn QScopedPointer::QScopedPointer(T *p = 0) + \fn template QScopedPointer::QScopedPointer(T *p = 0) Constructs this QScopedPointer instance and sets its pointer to \a p. */ /*! - \fn QScopedPointer::~QScopedPointer() + \fn template QScopedPointer::~QScopedPointer() Destroys this QScopedPointer object. Delete the object its pointer points to. */ /*! - \fn T *QScopedPointer::data() const + \fn template T *QScopedPointer::data() const Returns the value of the pointer referenced by this object. QScopedPointer still owns the object pointed to. */ /*! - \fn T *QScopedPointer::get() const + \fn template T *QScopedPointer::get() const \since 5.11 Same as data(). */ /*! - \fn T &QScopedPointer::operator*() const + \fn template T &QScopedPointer::operator*() const Provides access to the scoped pointer's object. @@ -162,7 +162,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn T *QScopedPointer::operator->() const + \fn template T *QScopedPointer::operator->() const Provides access to the scoped pointer's object. @@ -172,7 +172,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn QScopedPointer::operator bool() const + \fn template QScopedPointer::operator bool() const Returns \c true if this object is not \c null. This function is suitable for use in \tt if-constructs, like: @@ -183,7 +183,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn bool operator==(const QScopedPointer &lhs, const QScopedPointer &rhs) + \fn template bool operator==(const QScopedPointer &lhs, const QScopedPointer &rhs) Equality operator. Returns \c true if the scoped pointers \a lhs and \a rhs are pointing to the same object. @@ -192,7 +192,7 @@ QT_BEGIN_NAMESPACE /*! - \fn bool operator!=(const QScopedPointer &lhs, const QScopedPointer &rhs) + \fn template bool operator!=(const QScopedPointer &lhs, const QScopedPointer &rhs) Inequality operator. Returns \c true if the scoped pointers \a lhs and \a rhs are \e not pointing to the same object. @@ -200,7 +200,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn bool operator==(const QScopedPointer &lhs, std::nullptr_t) + \fn template bool operator==(const QScopedPointer &lhs, std::nullptr_t) \relates QScopedPointer \since 5.8 @@ -210,7 +210,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn bool operator==(std::nullptr_t, const QScopedPointer &rhs) + \fn template bool operator==(std::nullptr_t, const QScopedPointer &rhs) \relates QScopedPointer \since 5.8 @@ -220,7 +220,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn bool operator!=(const QScopedPointer &lhs, std::nullptr_t) + \fn template bool operator!=(const QScopedPointer &lhs, std::nullptr_t) \relates QScopedPointer \since 5.8 @@ -231,7 +231,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn bool operator!=(std::nullptr_t, const QScopedPointer &rhs) + \fn template bool operator!=(std::nullptr_t, const QScopedPointer &rhs) \relates QScopedPointer \since 5.8 @@ -242,13 +242,13 @@ QT_BEGIN_NAMESPACE */ /*! - \fn bool QScopedPointer::isNull() const + \fn template bool QScopedPointer::isNull() const Returns \c true if this object is holding a pointer that is \c null. */ /*! - \fn void QScopedPointer::reset(T *other = 0) + \fn template void QScopedPointer::reset(T *other = 0) Deletes the existing object it is pointing to if any, and sets its pointer to \a other. QScopedPointer now owns \a other and will delete it in its @@ -256,7 +256,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn T *QScopedPointer::take() + \fn template T *QScopedPointer::take() Returns the value of the pointer referenced by this object. The pointer of this QScopedPointer object will be reset to \c null. @@ -264,7 +264,7 @@ QT_BEGIN_NAMESPACE Callers of this function take ownership of the pointer. */ -/*! \fn bool QScopedPointer::operator!() const +/*! \fn template bool QScopedPointer::operator!() const Returns \c true if the pointer referenced by this object is \c null, otherwise returns \c false. @@ -272,7 +272,7 @@ QT_BEGIN_NAMESPACE \sa isNull() */ -/*! \fn void QScopedPointer::swap(QScopedPointer &other) +/*! \fn template void QScopedPointer::swap(QScopedPointer &other) Swap this pointer with \a other. */ @@ -304,20 +304,20 @@ QT_BEGIN_NAMESPACE */ /*! - \fn QScopedArrayPointer::QScopedArrayPointer() + \fn template QScopedArrayPointer::QScopedArrayPointer() Constructs a QScopedArrayPointer instance. */ /*! - \fn QScopedArrayPointer::QScopedArrayPointer(D * p) + \fn template template QScopedArrayPointer::QScopedArrayPointer(D * p) Constructs a QScopedArrayPointer and stores the array of objects pointed to by \a p. */ /*! - \fn T *QScopedArrayPointer::operator[](int i) + \fn template T *QScopedArrayPointer::operator[](int i) Provides access to entry \a i of the scoped pointer's array of objects. @@ -328,7 +328,7 @@ QT_BEGIN_NAMESPACE */ /*! - \fn T *QScopedArrayPointer::operator[](int i) const + \fn template T *QScopedArrayPointer::operator[](int i) const Provides access to entry \a i of the scoped pointer's array of objects. @@ -338,4 +338,8 @@ QT_BEGIN_NAMESPACE \sa isNull() */ +/*! \fn template void QScopedArrayPointer::swap(QScopedArrayPointer &other) + Swap this pointer with \a other. + */ + QT_END_NAMESPACE -- cgit v1.2.3