diff options
| author | Saleem Abdulrasool <compnerd@compnerd.org> | 2016-12-31 18:13:34 +0000 | 
|---|---|---|
| committer | Saleem Abdulrasool <compnerd@compnerd.org> | 2016-12-31 18:13:34 +0000 | 
| commit | 2177f3ce5f7da6f1fc71868066ef716f860091b9 (patch) | |
| tree | 9cda3a73ff35c36c3c192b7a138026e773b28c15 | |
| parent | 94865f9ab092eeeda7cf830a3f5f23f6249594a1 (diff) | |
| download | bcm5719-llvm-2177f3ce5f7da6f1fc71868066ef716f860091b9.tar.gz bcm5719-llvm-2177f3ce5f7da6f1fc71868066ef716f860091b9.zip  | |
clean up some qualifier casting
This cleans up the `-Wqual-cast` warnings from gcc 6 when building
libc++.  NFC.
llvm-svn: 290789
| -rw-r--r-- | libcxx/include/__std_stream | 2 | ||||
| -rw-r--r-- | libcxx/include/type_traits | 3 | 
2 files changed, 3 insertions, 2 deletions
diff --git a/libcxx/include/__std_stream b/libcxx/include/__std_stream index f867cd23bdd..fb5a346f10d 100644 --- a/libcxx/include/__std_stream +++ b/libcxx/include/__std_stream @@ -297,7 +297,7 @@ __stdoutbuf<_CharT>::overflow(int_type __c)                          return traits_type::eof();                      if (__r == codecvt_base::partial)                      { -                        pbase = (char_type*)__e; +                        pbase = const_cast<char_type*>(__e);                      }                  }                  else diff --git a/libcxx/include/type_traits b/libcxx/include/type_traits index f6a016d0b76..e2b537799dc 100644 --- a/libcxx/include/type_traits +++ b/libcxx/include/type_traits @@ -443,7 +443,8 @@ inline _LIBCPP_NO_CFI _LIBCPP_INLINE_VISIBILITY  _Tp*  addressof(_Tp& __x) _NOEXCEPT  { -    return (_Tp*)&reinterpret_cast<const volatile char&>(__x); +  return reinterpret_cast<_Tp *>( +      const_cast<char *>(&reinterpret_cast<const volatile char &>(__x)));  }  #endif // _LIBCPP_HAS_NO_BUILTIN_ADDRESSOF  | 

