diff options
author | frosch <frosch@openttd.org> | 2017-08-13 18:38:42 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2017-08-13 18:38:42 +0000 |
commit | b4b98e51655012ea42dbc8ab9e455fbec0d04b39 (patch) | |
tree | 948fc802d5dfdca71454f6ce479e4f429e98488d /src/train_cmd.cpp | |
parent | 19bae485b028380fbdc94d02ebaecdf3ca23f932 (diff) | |
download | openttd-b4b98e51655012ea42dbc8ab9e455fbec0d04b39.tar.xz |
(svn r27893) -Codechange: Use fallthrough attribute. (LordAro)
Diffstat (limited to 'src/train_cmd.cpp')
-rw-r--r-- | src/train_cmd.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/train_cmd.cpp b/src/train_cmd.cpp index 608ce2fee..fb1d2b1ee 100644 --- a/src/train_cmd.cpp +++ b/src/train_cmd.cpp @@ -2502,6 +2502,7 @@ public: case OT_GOTO_DEPOT: /* Skip service in depot orders when the train doesn't need service. */ if ((order->GetDepotOrderType() & ODTFB_SERVICE) && !this->v->NeedsServicing()) break; + FALLTHROUGH; case OT_GOTO_STATION: case OT_GOTO_WAYPOINT: this->v->current_order = *order; @@ -3608,7 +3609,7 @@ static bool TrainApproachingLineEnd(Train *v, bool signal, bool reverse) * for other directions, it will be 1, 3, 5, ..., 15 */ switch (v->direction) { case DIR_N : x = ~x + ~y + 25; break; - case DIR_NW: x = y; // FALL THROUGH + case DIR_NW: x = y; FALLTHROUGH; case DIR_NE: x = ~x + 16; break; case DIR_E : x = ~x + y + 9; break; case DIR_SE: x = y; break; |