From: Israël Hallé Date: Thu, 10 Jul 2014 03:09:24 +0000 (-0400) Subject: Fix VS2013 compiler error in Entity_test.cc X-Git-Url: https://code.bitgloo.com/?a=commitdiff_plain;h=34a9e088b0c109ba65bfc777273d4c37a07e1bc6;p=clyne%2Fentityx.git Fix VS2013 compiler error in Entity_test.cc --- diff --git a/entityx/Entity_test.cc b/entityx/Entity_test.cc old mode 100644 new mode 100755 index 1c47453..ee1ccac --- a/entityx/Entity_test.cc +++ b/entityx/Entity_test.cc @@ -337,6 +337,10 @@ TEST_CASE_METHOD(EntityManagerFixture, "TestEntityDestroyedEvent") { TEST_CASE_METHOD(EntityManagerFixture, "TestComponentAddedEvent") { struct ComponentAddedEventReceiver : public Receiver { + + ComponentAddedEventReceiver() + : position_events(0), direction_events(0) {} + void receive(const ComponentAddedEvent &event) { auto p = event.component; float n = static_cast(position_events); @@ -353,8 +357,8 @@ TEST_CASE_METHOD(EntityManagerFixture, "TestComponentAddedEvent") { direction_events++; } - int position_events = 0; - int direction_events = 0; + int position_events; + int direction_events; }; ComponentAddedEventReceiver receiver;