projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7d0ec12
)
Disable CFI checks in std::addressof.
author
Evgeniy Stepanov
<eugeni.stepanov@gmail.com>
Fri, 11 Mar 2016 23:50:57 +0000
(23:50 +0000)
committer
Evgeniy Stepanov
<eugeni.stepanov@gmail.com>
Fri, 11 Mar 2016 23:50:57 +0000
(23:50 +0000)
std::addressof may be used on a storage of an object before the start
of its lifetime (see std::allocate_shared for example). CFI flags the
C-style cast as invalid in that case.
llvm-svn: 263310
libcxx/include/type_traits
patch
|
blob
|
history
diff --git
a/libcxx/include/type_traits
b/libcxx/include/type_traits
index
33124d2
..
47f9334
100644
(file)
--- a/
libcxx/include/type_traits
+++ b/
libcxx/include/type_traits
@@
-399,7
+399,7
@@
template <bool _Bp, class _Tp = void> using enable_if_t = typename enable_if<_Bp
// addressof
template <class _Tp>
-inline _LIBCPP_INLINE_VISIBILITY
+inline _LIBCPP_
NO_CFI _LIBCPP_
INLINE_VISIBILITY
_Tp*
addressof(_Tp& __x) _NOEXCEPT
{