From 3896bf7453f2c807f2fb3de55b978da433fa5aec Mon Sep 17 00:00:00 2001 From: Eric Fiselier Date: Tue, 4 Apr 2017 01:05:59 +0000 Subject: [PATCH] Work around recent -Wshadow changes in Clang llvm-svn: 299407 --- libcxx/include/experimental/filesystem | 11 +++++++++++ libcxx/include/regex | 1 - 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/libcxx/include/experimental/filesystem b/libcxx/include/experimental/filesystem index cf62ca2..04180d1 100644 --- a/libcxx/include/experimental/filesystem +++ b/libcxx/include/experimental/filesystem @@ -1091,7 +1091,18 @@ class _LIBCPP_TYPE_VIS path::iterator { public: typedef bidirectional_iterator_tag iterator_category; + + // FIXME: As of 3/April/2017 Clang warns on `value_type` shadowing the + // definition in path. Clang should be fixed and this should be removed. +#if defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wshadow" +#endif typedef path value_type; +#if defined(__clang__) +#pragma clang diagnostic pop +#endif + typedef std::ptrdiff_t difference_type; typedef const path* pointer; typedef const path& reference; diff --git a/libcxx/include/regex b/libcxx/include/regex index 42e55e8..fe97a63 100644 --- a/libcxx/include/regex +++ b/libcxx/include/regex @@ -3957,7 +3957,6 @@ basic_regex<_CharT, _Traits>::__parse_equivalence_class(_ForwardIterator __first if (__temp == __last) __throw_regex_error(); // [__first, __temp) contains all text in [= ... =] - typedef typename _Traits::string_type string_type; string_type __collate_name = __traits_.lookup_collatename(__first, __temp); if (__collate_name.empty()) -- 2.7.4