diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2015-02-16 13:38:13 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2015-02-16 13:38:13 +0300 |
commit | 9daac198f5610b7e7bb5354789082b97a8e11b36 (patch) | |
tree | b952c81626d39e3a2605620096bf2bff32eed363 /intern/cycles/util | |
parent | 9a10b208bacd4258e528532d400b25aeb33591d9 (diff) |
Cycles: Correction for C++11 compilation error after recent vector changes
Diffstat (limited to 'intern/cycles/util')
-rw-r--r-- | intern/cycles/util/util_vector.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/intern/cycles/util/util_vector.h b/intern/cycles/util/util_vector.h index cf8fd22fe0e..92c3f116c69 100644 --- a/intern/cycles/util/util_vector.h +++ b/intern/cycles/util/util_vector.h @@ -69,12 +69,14 @@ public: /* Copy constructor. */ vector(const vector &x) : std::vector<value_type, allocator_type>(x) { } -#if __cplusplus < 201103L void shrink_to_fit(void) { +#if __cplusplus < 201103L vector<value_type>().swap(*this); - } +#else + std::vector<value_type, allocator_type>::shrink_to_fit(); #endif + } void free_memory(void) { std::vector<value_type, allocator_type>::resize(0); |