mirror of
https://github.com/firebase/leveldb
synced 2026-11-09 22:25:58 +05:45
fix C++20 compliance with application of upstream PR 965
These symbols are no longer valid on macOS and will fail builds if the `NDEBUG` symbol is defined, as it is now in default build settings for all react-native projects since release of react-native 0.76 This same change was applied upstream but never released, and it appears it has not been applied here https://github.com/google/leveldb/pull/965#issuecomment-2436371816
This commit is contained in:
1 parent
2cc3364406
commit
dc346ebc29
1 file changed
+2
-2
+2
-2
@@ -837,7 +837,7 @@ class SingletonEnv {
|
||||
public:
|
||||
SingletonEnv() {
|
||||
#if !defined(NDEBUG)
|
||||
env_initialized_.store(true, std::memory_order::memory_order_relaxed);
|
||||
env_initialized_.store(true, std::memory_order_relaxed);
|
||||
#endif // !defined(NDEBUG)
|
||||
static_assert(sizeof(env_storage_) >= sizeof(EnvType),
|
||||
"env_storage_ will not fit the Env");
|
||||
@@ -854,7 +854,7 @@ class SingletonEnv {
|
||||
|
||||
static void AssertEnvNotInitialized() {
|
||||
#if !defined(NDEBUG)
|
||||
assert(!env_initialized_.load(std::memory_order::memory_order_relaxed));
|
||||
assert(!env_initialized_.load(std::memory_order_relaxed));
|
||||
#endif // !defined(NDEBUG)
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user