diff options
author | Howard Hinnant <hhinnant@apple.com> | 2011-11-29 18:15:50 +0000 |
---|---|---|
committer | Howard Hinnant <hhinnant@apple.com> | 2011-11-29 18:15:50 +0000 |
commit | c003db1fcae660d055b1b29852065f67bbabd35e (patch) | |
tree | af77ff4d08341945ef328dddea31ed7c8919ca82 /libcxx/include/mutex | |
parent | de3a2118db444f4a612ff6b9487face43eb512a6 (diff) | |
download | bcm5719-llvm-c003db1fcae660d055b1b29852065f67bbabd35e.tar.gz bcm5719-llvm-c003db1fcae660d055b1b29852065f67bbabd35e.zip |
Further macro protection by replacing _[A-Z] with _[A-Z]p
llvm-svn: 145410
Diffstat (limited to 'libcxx/include/mutex')
-rw-r--r-- | libcxx/include/mutex | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/libcxx/include/mutex b/libcxx/include/mutex index d1d0a6e0587..8bc6b800141 100644 --- a/libcxx/include/mutex +++ b/libcxx/include/mutex @@ -464,23 +464,23 @@ private: #ifndef _LIBCPP_HAS_NO_VARIADICS -template <class _F> +template <class _Fp> class __call_once_param { - _F __f_; + _Fp __f_; public: #ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES _LIBCPP_INLINE_VISIBILITY - explicit __call_once_param(_F&& __f) : __f_(_VSTD::move(__f)) {} + explicit __call_once_param(_Fp&& __f) : __f_(_VSTD::move(__f)) {} #else _LIBCPP_INLINE_VISIBILITY - explicit __call_once_param(const _F& __f) : __f_(__f) {} + explicit __call_once_param(const _Fp& __f) : __f_(__f) {} #endif _LIBCPP_INLINE_VISIBILITY void operator()() { - typedef typename __make_tuple_indices<tuple_size<_F>::value, 1>::type _Index; + typedef typename __make_tuple_indices<tuple_size<_Fp>::value, 1>::type _Index; __execute(_Index()); } @@ -495,17 +495,17 @@ private: #else -template <class _F> +template <class _Fp> class __call_once_param { - _F __f_; + _Fp __f_; public: #ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES _LIBCPP_INLINE_VISIBILITY - explicit __call_once_param(_F&& __f) : __f_(_VSTD::move(__f)) {} + explicit __call_once_param(_Fp&& __f) : __f_(_VSTD::move(__f)) {} #else _LIBCPP_INLINE_VISIBILITY - explicit __call_once_param(const _F& __f) : __f_(__f) {} + explicit __call_once_param(const _Fp& __f) : __f_(__f) {} #endif _LIBCPP_INLINE_VISIBILITY @@ -517,11 +517,11 @@ public: #endif -template <class _F> +template <class _Fp> void __call_once_proxy(void* __vp) { - __call_once_param<_F>* __p = static_cast<__call_once_param<_F>*>(__vp); + __call_once_param<_Fp>* __p = static_cast<__call_once_param<_Fp>*>(__vp); (*__p)(); } @@ -536,10 +536,10 @@ call_once(once_flag& __flag, _Callable&& __func, _Args&&... __args) { if (__builtin_expect(__flag.__state_ , ~0ul) != ~0ul) { - typedef tuple<typename decay<_Callable>::type, typename decay<_Args>::type...> _G; - __call_once_param<_G> __p(_G(__decay_copy(_VSTD::forward<_Callable>(__func)), + typedef tuple<typename decay<_Callable>::type, typename decay<_Args>::type...> _Gp; + __call_once_param<_Gp> __p(_Gp(__decay_copy(_VSTD::forward<_Callable>(__func)), __decay_copy(_VSTD::forward<_Args>(__args))...)); - __call_once(__flag.__state_, &__p, &__call_once_proxy<_G>); + __call_once(__flag.__state_, &__p, &__call_once_proxy<_Gp>); } } |