[PATCH] Make __wrap_iter work with gcc
Nico Weber
thakis at chromium.org
Tue Jan 27 11:20:46 PST 2015
Add _LIBCPP_TYPE_VIS_ONLY to forward decl.
http://reviews.llvm.org/D7201
Files:
include/iterator
test/std/iterators/iterators.general/gcc_workaround.pass.cpp
Index: include/iterator
===================================================================
--- include/iterator
+++ include/iterator
@@ -1112,6 +1112,8 @@
>::type
__unwrap_iter(__wrap_iter<_Tp*>);
+template <class _Tp, class _Alloc> class _LIBCPP_TYPE_VIS_ONLY vector;
+
template <class _Iter>
class __wrap_iter
{
Index: test/std/iterators/iterators.general/gcc_workaround.pass.cpp
===================================================================
--- test/std/iterators/iterators.general/gcc_workaround.pass.cpp
+++ test/std/iterators/iterators.general/gcc_workaround.pass.cpp
@@ -0,0 +1,20 @@
+//===----------------------------------------------------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is dual licensed under the MIT and the University of Illinois Open
+// Source Licenses. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+// Tests workaround for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64816.
+
+#include <string>
+
+void f(const std::string &s) { s.begin(); }
+
+#include <vector>
+
+void AppendTo(const std::vector<char> &v) { v.begin(); }
+
+int main() {}
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7201.18832.patch
Type: text/x-patch
Size: 1215 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150127/daca86cc/attachment.bin>
More information about the cfe-commits
mailing list