Replace see-alsos in qfloat16 documentation with \overload

Explicitly specify the float-overload, otherwise it's just ends
up referring to itself, and won't generate a link.

Also document qFpClassify(qfloat16) overload. The internal
implementation was documented, but the public overload not.

Change-Id: Ifdc364597a0e7b4d943f0ec6d149977a15c805ef
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
bb10
Volker Hilsheimer 2020-10-26 10:21:59 +01:00
parent 1b4ea4a1d8
commit 0807ede08c
2 changed files with 19 additions and 23 deletions

View File

@ -1,6 +1,6 @@
/****************************************************************************
**
** Copyright (C) 2019 The Qt Company Ltd.
** Copyright (C) 2020 The Qt Company Ltd.
** Copyright (C) 2016 by Southwest Research Institute (R)
** Contact: http://www.qt-project.org/legal
**
@ -88,28 +88,25 @@ QT_BEGIN_NAMESPACE
/*!
\fn bool qIsInf(qfloat16 f)
\relates qfloat16
\overload qIsInf(float)
Returns true if the \c qfloat16 \a {f} is equivalent to infinity.
\sa qIsInf
*/
/*!
\fn bool qIsNaN(qfloat16 f)
\relates qfloat16
\overload qIsNaN(float)
Returns true if the \c qfloat16 \a {f} is not a number (NaN).
\sa qIsNaN
*/
/*!
\fn bool qIsFinite(qfloat16 f)
\relates qfloat16
\overload qIsFinite(float)
Returns true if the \c qfloat16 \a {f} is a finite number.
\sa qIsFinite
*/
/*!
@ -118,8 +115,6 @@ QT_BEGIN_NAMESPACE
\fn bool qfloat16::isInf() const noexcept
Tests whether this \c qfloat16 value is an infinity.
\sa qIsInf()
*/
/*!
@ -128,8 +123,6 @@ QT_BEGIN_NAMESPACE
\fn bool qfloat16::isNaN() const noexcept
Tests whether this \c qfloat16 value is "not a number".
\sa qIsNaN()
*/
/*!
@ -147,8 +140,6 @@ QT_BEGIN_NAMESPACE
\fn bool qfloat16::isFinite() const noexcept
Tests whether this \c qfloat16 value is finite.
\sa qIsFinite()
*/
/*!
@ -159,12 +150,19 @@ QT_BEGIN_NAMESPACE
from this qfloat16. Serves as qfloat16's equivalent of std::copysign().
*/
/*!
\fn int qFpClassify(qfloat16 val)
\relates qfloat16
\since 5.14
\overload qFpClassify(float)
Returns the floating-point class of \a val.
*/
/*!
\internal
\since 5.14
Implements qFpClassify() for qfloat16.
\sa qFpClassify()
*/
int qfloat16::fpClassify() const noexcept
{
@ -174,22 +172,21 @@ int qfloat16::fpClassify() const noexcept
/*! \fn int qRound(qfloat16 value)
\relates qfloat16
\overload qRound(float)
Rounds \a value to the nearest integer.
\sa qRound
*/
/*! \fn qint64 qRound64(qfloat16 value)
\relates qfloat16
\overload qRound64(float)
Rounds \a value to the nearest 64-bit integer.
\sa qRound64
*/
/*! \fn bool qFuzzyCompare(qfloat16 p1, qfloat16 p2)
\relates qfloat16
\overload qFuzzyCompare(float, float)
Compares the floating point value \a p1 and \a p2 and
returns \c true if they are considered equal, otherwise \c false.

View File

@ -104,6 +104,9 @@ Q_CORE_EXPORT double qQNaN() { return qt_qnan(); }
Q_CORE_EXPORT double qInf() { return qt_inf(); }
/*!
\fn int qFpClassify(double val)
\fn int qFpClassify(float val)
\relates <QtGlobal>
Classifies a floating-point value.
@ -118,10 +121,6 @@ Q_CORE_EXPORT double qInf() { return qt_inf(); }
\endlist
*/
Q_CORE_EXPORT int qFpClassify(double val) { return qt_fpclassify(val); }
/*!
\overload
*/
Q_CORE_EXPORT int qFpClassify(float val) { return qt_fpclassify(val); }