[libc++] fix std::sort(T**, T**)

previously, invocations of std::sort(T**, T**) casted the arguments to
(size_t *). this breaks sorting on systems for which pointers don't fit
in a size_t. change the cast to (uintptr_t *) and add a test.

Differential Revision: https://reviews.llvm.org/D92190
diff --git a/libcxx/include/algorithm b/libcxx/include/algorithm
index 970d36c..2a854e7 100644
--- a/libcxx/include/algorithm
+++ b/libcxx/include/algorithm
@@ -4162,7 +4162,7 @@
 void
 sort(_Tp** __first, _Tp** __last)
 {
-    _VSTD::sort((size_t*)__first, (size_t*)__last, __less<size_t>());
+    _VSTD::sort((uintptr_t*)__first, (uintptr_t*)__last, __less<uintptr_t>());
 }
 
 template <class _Tp>