From: Mikko Rasa Date: Fri, 31 May 2013 21:57:21 +0000 (+0300) Subject: Pull the SetFlag class from mspcore X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=59115614ee941fe801416aca2f8f380065bdc2b7;p=r2c2.git Pull the SetFlag class from mspcore --- diff --git a/source/libr2c2/train.cpp b/source/libr2c2/train.cpp index 7de6236..d78e627 100644 --- a/source/libr2c2/train.cpp +++ b/source/libr2c2/train.cpp @@ -1,6 +1,7 @@ #include #include #include +#include #include #include #include @@ -23,19 +24,6 @@ using namespace std; using namespace Msp; -namespace { - -struct SetFlag -{ - bool &flag; - - SetFlag(bool &f): flag(f) { flag = true; } - ~SetFlag() { flag = false; } -}; - -} - - namespace R2C2 { Train::Train(Layout &l, const VehicleType &t, unsigned a, const string &p):