Page MenuHome

Fix build error on Linux + Clang 10 after recent changes to BLI_any
ClosedPublic

Authored by Brecht Van Lommel (brecht) on Apr 25 2022, 2:59 PM.

Diff Detail

Repository
rB Blender
Branch
master
Build Status
Buildable 21788
Build 21788: arc lint + arc unit

Event Timeline

1In file included from /home/brecht/dev/blender/source/blender/blenlib/tests/BLI_any_test.cc:3:
2/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:56:39: error: no member named 'Ptr' in 'std::unique_ptr<blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator>, std::default_delete<blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator> > >'
3 [](void *src) { ((Ptr<T> *)src)->~Ptr<T>(); },
4 ^
5/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:137:31: note: in instantiation of variable template specialization 'blender::detail::info_for_unique_ptr<blender::detail::NoExtraInfo, blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator> >' requested here
6 return detail::template info_for_unique_ptr<RealExtraInfo, DecayT>;
7 ^
8/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:243:29: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::get_info<blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator> >' requested here
9 info_ = &this->template get_info<DecayT>();
10 ^
11/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:168:11: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::emplace_on_empty<blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator>, blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator> >' requested here
12 this->emplace_on_empty<T>(std::forward<Args>(args)...);
13 ^
14/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:175:20: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::Any<blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator>, blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator> >' requested here
15 Any(T &&value) : Any(std::in_place_type<T>, std::forward<T>(value))
16 ^
17/home/brecht/dev/blender/source/blender/blenlib/tests/BLI_any_test.cc:43:13: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::Any<blender::Map<int, int, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, int>, blender::GuardedAllocator>, nullptr>' requested here
18 Any<> a = Map<int, int>();
19 ^
20In file included from /home/brecht/dev/blender/source/blender/blenlib/tests/BLI_any_test.cc:3:
21/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:56:39: error: no member named 'Ptr' in 'std::unique_ptr<blender::Map<int, float, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, float>, blender::GuardedAllocator>, std::default_delete<blender::Map<int, float, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, float>, blender::GuardedAllocator> > >'
22 [](void *src) { ((Ptr<T> *)src)->~Ptr<T>(); },
23 ^
24/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:137:31: note: in instantiation of variable template specialization 'blender::detail::info_for_unique_ptr<blender::detail::NoExtraInfo, blender::Map<int, float, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, float>, blender::GuardedAllocator> >' requested here
25 return detail::template info_for_unique_ptr<RealExtraInfo, DecayT>;
26 ^
27/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:261:37: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::get_info<blender::Map<int, float, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, float>, blender::GuardedAllocator> >' requested here
28 return info_ == &this->template get_info<T>();
29 ^
30/home/brecht/dev/blender/source/blender/blenlib/tests/BLI_any_test.cc:46:19: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::is<blender::Map<int, float, 4, blender::PythonProbingStrategy<1, false>, blender::DefaultHash<int32_t>, blender::DefaultEquality, blender::SimpleMapSlot<int, float>, blender::GuardedAllocator> >' requested here
31 EXPECT_FALSE((a.is<Map<int, float>>()));
32 ^
33In file included from /home/brecht/dev/blender/source/blender/blenlib/tests/BLI_any_test.cc:3:
34/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:56:39: error: no member named 'Ptr' in 'std::unique_ptr<blender::Any<void, 8, 8>, std::default_delete<blender::Any<void, 8, 8> > >'
35 [](void *src) { ((Ptr<T> *)src)->~Ptr<T>(); },
36 ^
37/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:137:31: note: in instantiation of variable template specialization 'blender::detail::info_for_unique_ptr<blender::detail::NoExtraInfo, blender::Any<void, 8, 8> >' requested here
38 return detail::template info_for_unique_ptr<RealExtraInfo, DecayT>;
39 ^
40/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:243:29: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::get_info<blender::Any<void, 8, 8> >' requested here
41 info_ = &this->template get_info<DecayT>();
42 ^
43/home/brecht/dev/blender/source/blender/blenlib/BLI_any.hh:168:11: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::emplace_on_empty<blender::Any<void, 8, 8>, blender::Any<void, 8, 8> &>' requested here
44 this->emplace_on_empty<T>(std::forward<Args>(args)...);
45 ^
46/home/brecht/dev/blender/source/blender/blenlib/tests/BLI_any_test.cc:84:7: note: in instantiation of function template specialization 'blender::Any<void, 8, 8>::Any<blender::Any<void, 8, 8>, blender::Any<void, 8, 8> &>' requested here
47 z = Any(std::in_place_type<Any<>>, a);
48 ^
493 errors generated.

This revision is now accepted and ready to land.Apr 25 2022, 3:06 PM