QList: also default count()'s template parameter
Also fix the docs. Change-Id: If08116cb8657d00d610de9451be0ba73ce19dcd1 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This commit is contained in:
parent
e2e9ce8109
commit
1aa3459d0a
@ -352,7 +352,7 @@ public:
|
||||
bool contains(const AT &t) const noexcept;
|
||||
#endif
|
||||
|
||||
template <typename AT>
|
||||
template <typename AT = T>
|
||||
qsizetype count(const AT &t) const noexcept
|
||||
{
|
||||
return qsizetype(std::count(&*cbegin(), &*cend(), t));
|
||||
|
@ -1013,7 +1013,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/*! \fn template <typename T> qsizetype QList<T>::count(parameter_type value) const
|
||||
/*! \fn template <typename T> template <typename AT = T> qsizetype QList<T>::count(const AT &value) const
|
||||
|
||||
Returns the number of occurrences of \a value in the list.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user