Fix compilation with GCC 4.9
4.9 does not correctly implement C++14 aggregate initialization.
This commit is contained in:
parent
99037a7c72
commit
143cc3b696
|
@ -30,11 +30,11 @@ CachedRealm::CachedRealm(const std::shared_ptr<Realm>& realm, bool cache)
|
|||
{
|
||||
struct RefCountedWeakPointer {
|
||||
std::weak_ptr<Realm> realm;
|
||||
std::atomic<size_t> ref_count = {1};
|
||||
std::atomic<size_t> ref_count;
|
||||
};
|
||||
|
||||
CFRunLoopSourceContext ctx{};
|
||||
ctx.info = new RefCountedWeakPointer{realm};
|
||||
ctx.info = new RefCountedWeakPointer{realm, {1}};
|
||||
ctx.perform = [](void* info) {
|
||||
if (auto realm = static_cast<RefCountedWeakPointer*>(info)->realm.lock()) {
|
||||
realm->notify();
|
||||
|
|
|
@ -28,7 +28,7 @@ class Schema;
|
|||
namespace parser {
|
||||
struct Expression
|
||||
{
|
||||
enum class Type { None, Number, String, KeyPath, Argument, True, False } type = Type::None;
|
||||
enum class Type { None, Number, String, KeyPath, Argument, True, False } type;
|
||||
std::string s;
|
||||
};
|
||||
|
||||
|
@ -60,7 +60,7 @@ struct Predicate
|
|||
struct Comparison
|
||||
{
|
||||
Operator op = Operator::None;
|
||||
Expression expr[2];
|
||||
Expression expr[2] = {{Expression::Type::None, ""}, {Expression::Type::None, ""}};
|
||||
};
|
||||
|
||||
struct Compound
|
||||
|
|
Loading…
Reference in New Issue