diff options
author | Anders Carlsson <andersca@mac.com> | 2013-07-22 21:08:00 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2013-07-22 21:08:00 +0000 |
commit | 8bb1dbbf7544eaac3afab8d1f91b71f383dab903 (patch) | |
tree | e8ef051c1db393b5fbf0f51b68f7f19ae5634c65 /libcxx/include/algorithm | |
parent | c0659fad7fc6867bf5def77ab1940bc93551b368 (diff) | |
download | bcm5719-llvm-8bb1dbbf7544eaac3afab8d1f91b71f383dab903.tar.gz bcm5719-llvm-8bb1dbbf7544eaac3afab8d1f91b71f383dab903.zip |
Fix a bug in std::fill_n where memset would end up being called in cases when it shouldn’t.
Reviewed by Howard.
llvm-svn: 186875
Diffstat (limited to 'libcxx/include/algorithm')
-rw-r--r-- | libcxx/include/algorithm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libcxx/include/algorithm b/libcxx/include/algorithm index 703a9b3dce1..19d016fb7d5 100644 --- a/libcxx/include/algorithm +++ b/libcxx/include/algorithm @@ -2011,8 +2011,8 @@ fill_n(_OutputIterator __first, _Size __n, const _Tp& __value_) { return _VSTD::__fill_n(__first, __n, __value_, integral_constant<bool, is_pointer<_OutputIterator>::value && - is_trivially_copy_assignable<_Tp>::value && - sizeof(_Tp) == 1>()); + is_trivially_assignable<typename remove_pointer<_OutputIterator>::type, _Tp>::value && + sizeof(typename remove_pointer<_OutputIterator>::type) == 1>()); } // fill |