// Vector implementation (out of line) -*- C++ -*-
-// Copyright (C) 2001-2019 Free Software Foundation, Inc.
+// Copyright (C) 2001-2020 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
const size_type __old_size = size();
pointer __tmp;
#if __cplusplus >= 201103L
- if constexpr (_S_use_relocate())
+ if _GLIBCXX17_CONSTEXPR (_S_use_relocate())
{
__tmp = this->_M_allocate(__n);
- std::__relocate_a(this->_M_impl._M_start,
- this->_M_impl._M_finish,
- __tmp, _M_get_Tp_allocator());
+ _S_relocate(this->_M_impl._M_start, this->_M_impl._M_finish,
+ __tmp, _M_get_Tp_allocator());
}
else
#endif
__new_finish = pointer();
#if __cplusplus >= 201103L
- if constexpr (_S_use_relocate())
+ if _GLIBCXX17_CONSTEXPR (_S_use_relocate())
{
- __new_finish
- = std::__relocate_a
- (__old_start, __position.base(),
- __new_start, _M_get_Tp_allocator());
+ __new_finish = _S_relocate(__old_start, __position.base(),
+ __new_start, _M_get_Tp_allocator());
++__new_finish;
- __new_finish
- = std::__relocate_a
- (__position.base(), __old_finish,
- __new_finish, _M_get_Tp_allocator());
+ __new_finish = _S_relocate(__position.base(), __old_finish,
+ __new_finish, _M_get_Tp_allocator());
}
else
#endif
__throw_exception_again;
}
#if __cplusplus >= 201103L
- if constexpr (!_S_use_relocate())
+ if _GLIBCXX17_CONSTEXPR (!_S_use_relocate())
#endif
std::_Destroy(__old_start, __old_finish, _M_get_Tp_allocator());
_GLIBCXX_ASAN_ANNOTATE_REINIT;
const size_type __len =
_M_check_len(__n, "vector::_M_default_append");
pointer __new_start(this->_M_allocate(__len));
-#if __cplusplus >= 201103L
- if constexpr (_S_use_relocate())
+ if _GLIBCXX17_CONSTEXPR (_S_use_relocate())
{
__try
{
_M_deallocate(__new_start, __len);
__throw_exception_again;
}
- std::__relocate_a(this->_M_impl._M_start,
- this->_M_impl._M_finish,
- __new_start, _M_get_Tp_allocator());
+ _S_relocate(this->_M_impl._M_start, this->_M_impl._M_finish,
+ __new_start, _M_get_Tp_allocator());
}
else
-#endif
{
pointer __destroy_from = pointer();
__try