We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c83554e commit 4d18676Copy full SHA for 4d18676
include/bitcoin/system/allocator.hpp
@@ -118,7 +118,12 @@ class allocator
118
auto ptr = allocate_object<Type>();
119
construct_guard<Type> guard{ arena_, ptr };
120
construct<Type>(ptr, std::forward<Args>(args)...);
121
+
122
+ // Bogus warning (under LTCG only).
123
+ BC_PUSH_WARNING(UNREACHABLE_CODE)
124
guard.arena_ = nullptr;
125
+ BC_POP_WARNING()
126
127
return ptr;
128
}
129
include/bitcoin/system/warnings.hpp
@@ -44,6 +44,7 @@
44
#define THROW_FROM_NOEXCEPT 4297
45
#define TRUNCATED_CONSTANT 4310
46
#define LOCAL_VARIABLE_NOT_INITIALIZED 4700
47
+ #define UNREACHABLE_CODE 4702
48
#define NOT_INLINED 4714
49
#define DISCARDING_NON_DISCARDABLE 4834
50
0 commit comments