From e0d2b50249839d10ecf87abc296b8020046d1d75 Mon Sep 17 00:00:00 2001 From: Giuseppe D'Angelo Date: Tue, 30 Apr 2019 09:44:18 +0200 Subject: QList: do not call std::swap directly; use ADL Change-Id: Iaf6b965dd123f39436ba134ea1065d8dc4278c1e Reviewed-by: Thiago Macieira --- src/corelib/tools/qlist.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/corelib/tools/qlist.h') diff --git a/src/corelib/tools/qlist.h b/src/corelib/tools/qlist.h index dfb8a8a4ab..48a71b0ecf 100644 --- a/src/corelib/tools/qlist.h +++ b/src/corelib/tools/qlist.h @@ -709,7 +709,8 @@ inline void QList::swapItemsAt(int i, int j) Q_ASSERT_X(i >= 0 && i < p.size() && j >= 0 && j < p.size(), "QList::swap", "index out of range"); detach(); - std::swap(d->array[d->begin + i], d->array[d->begin + j]); + using std::swap; + swap(d->array[d->begin + i], d->array[d->begin + j]); } template -- cgit v1.2.3