[Scummvm-git-logs] scummvm master -> bc952807ecc73cf827a779adf1704bffe8a1db2f

bgK bastien.bouclet at gmail.com
Sun Jul 23 12:36:16 CEST 2017


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
bc952807ec TITANIC: Adjust the switch/case fall-through comments


Commit: bc952807ecc73cf827a779adf1704bffe8a1db2f
    https://github.com/scummvm/scummvm/commit/bc952807ecc73cf827a779adf1704bffe8a1db2f
Author: Bastien Bouclet (bastien.bouclet at gmail.com)
Date: 2017-07-23T11:12:12+02:00

Commit Message:
TITANIC: Adjust the switch/case fall-through comments

This way, GCC 7 does not generate a warning for those cases when
-Wimplicit-fallthrough=3 is enabled, which is now the default.

Changed paths:
    engines/titanic/core/game_object.cpp
    engines/titanic/core/link_item.cpp
    engines/titanic/core/project_item.cpp
    engines/titanic/core/room_item.cpp
    engines/titanic/core/view_item.cpp
    engines/titanic/game/place_holder_item.cpp
    engines/titanic/game/variable_list.cpp
    engines/titanic/main_game_window.cpp
    engines/titanic/true_talk/barbot_script.cpp
    engines/titanic/true_talk/bellbot_script.cpp


diff --git a/engines/titanic/core/game_object.cpp b/engines/titanic/core/game_object.cpp
index c4467c1..870e9d4 100644
--- a/engines/titanic/core/game_object.cpp
+++ b/engines/titanic/core/game_object.cpp
@@ -141,27 +141,27 @@ void CGameObject::load(SimpleFile *file) {
 	case 7:
 		_movieRangeInfoList.load(file);
 		_frameNumber = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 6:
 		_cursorId = (CursorId)file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 5:
 		_movieClips.load(file);
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 4:
 		_handleMouseFlag = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 3:
 		_nonvisual = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 2:
 		_resource = file->readString();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 1:
 		_bounds = file->readBounds();
diff --git a/engines/titanic/core/link_item.cpp b/engines/titanic/core/link_item.cpp
index 559191e..977d2f1 100644
--- a/engines/titanic/core/link_item.cpp
+++ b/engines/titanic/core/link_item.cpp
@@ -96,11 +96,11 @@ void CLinkItem::load(SimpleFile *file) {
 	switch (val) {
 	case 2:
 		_cursorId = (CursorId)file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 1:
 		_linkMode = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 0:
 		_roomNumber = file->readNumber();
diff --git a/engines/titanic/core/project_item.cpp b/engines/titanic/core/project_item.cpp
index 5a530a8..a3ac284 100644
--- a/engines/titanic/core/project_item.cpp
+++ b/engines/titanic/core/project_item.cpp
@@ -102,7 +102,7 @@ void CProjectItem::load(SimpleFile *file) {
 	case 1:
 		file->readBuffer();
 		_nextRoomNumber = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 0:
 		// Load the list of files
@@ -116,16 +116,16 @@ void CProjectItem::load(SimpleFile *file) {
 	case 6:
 		file->readBuffer();
 		_nextObjectNumber = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 5:
 		file->readBuffer();
 		_nextMessageNumber = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 4:
 		file->readBuffer();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 2:
 	case 3:
diff --git a/engines/titanic/core/room_item.cpp b/engines/titanic/core/room_item.cpp
index afac3ec..534fa5c 100644
--- a/engines/titanic/core/room_item.cpp
+++ b/engines/titanic/core/room_item.cpp
@@ -65,14 +65,14 @@ void CRoomItem::load(SimpleFile *file) {
 		// Read exit movie
 		file->readBuffer();
 		_exitMovieKey.load(file);
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 2:
 		// Read room dimensions
 		file->readBuffer();
 		_roomDimensionX = (double)file->readNumber() / 1000.0;
 		_roomDimensionY = (double)file->readNumber() / 1000.0;
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 1:
 		// Read transition movie key and clip list
@@ -82,7 +82,7 @@ void CRoomItem::load(SimpleFile *file) {
 		file->readBuffer();
 		_clipList.load(file);
 		postLoad();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 0:
 		// Read room rect
diff --git a/engines/titanic/core/view_item.cpp b/engines/titanic/core/view_item.cpp
index d0f5c8a..4e37fd2 100644
--- a/engines/titanic/core/view_item.cpp
+++ b/engines/titanic/core/view_item.cpp
@@ -67,7 +67,7 @@ void CViewItem::load(SimpleFile *file) {
 	switch (val) {
 	case 1:
 		_resourceKey.load(file);
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	default:
 		file->readBuffer();
diff --git a/engines/titanic/game/place_holder_item.cpp b/engines/titanic/game/place_holder_item.cpp
index 108c25c..dcde956 100644
--- a/engines/titanic/game/place_holder_item.cpp
+++ b/engines/titanic/game/place_holder_item.cpp
@@ -52,35 +52,35 @@ void CPlaceHolderItem::load(SimpleFile *file) {
 	switch (file->readNumber()) {
 	case 7:
 		_field7C = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 6:
 		file->readString();
 		_clips.load(file);
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 5:
 		_field68 = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 4:
 		_field64 = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 3:
 		_field60 = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 2:
 		_list.load(file);
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 1:
 		_string2 = file->readString();
 		_field4C = file->readNumber();
 		_pos1 = file->readPoint();
 		_pos2 = file->readPoint();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 0:
 		_string1 = file->readString();
diff --git a/engines/titanic/game/variable_list.cpp b/engines/titanic/game/variable_list.cpp
index 2a4a7df..9c73bbc 100644
--- a/engines/titanic/game/variable_list.cpp
+++ b/engines/titanic/game/variable_list.cpp
@@ -43,16 +43,16 @@ void CVariableListItem::load(SimpleFile *file) {
 	switch (file->readNumber()) {
 	case 3:
 		field44 = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 2:
 		_string1 = file->readString();
 		_field18 = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 1:
 		field40 = file->readNumber();
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 0:
 		_string2 = file->readString();
diff --git a/engines/titanic/main_game_window.cpp b/engines/titanic/main_game_window.cpp
index f3753b1..1d35f8e 100644
--- a/engines/titanic/main_game_window.cpp
+++ b/engines/titanic/main_game_window.cpp
@@ -158,7 +158,8 @@ void CMainGameWindow::draw() {
 			_project->loadGame(_pendingLoadSlot);
 			_pendingLoadSlot = -1;
 
-			// Deliberate fall-through to draw loaded game
+			// Intentional fall-through
+			// to draw loaded game
 
 		case GSMODE_INTERACTIVE:
 		case GSMODE_CUTSCENE:
diff --git a/engines/titanic/true_talk/barbot_script.cpp b/engines/titanic/true_talk/barbot_script.cpp
index ae4104c..627df6f 100644
--- a/engines/titanic/true_talk/barbot_script.cpp
+++ b/engines/titanic/true_talk/barbot_script.cpp
@@ -315,7 +315,7 @@ int BarbotScript::process(const TTroomScript *roomScript, const TTsentence *sent
 		} else if (flag2) {
 			return applySentenceIds(51423);
 		}
-		// Deliberate fall-through
+		// Intentional fall-through
 
 	case 16:
 		if (val2C == 7 || val2C == 10)
diff --git a/engines/titanic/true_talk/bellbot_script.cpp b/engines/titanic/true_talk/bellbot_script.cpp
index c958727..8e5633b 100644
--- a/engines/titanic/true_talk/bellbot_script.cpp
+++ b/engines/titanic/true_talk/bellbot_script.cpp
@@ -389,7 +389,7 @@ ScriptChangedResult BellbotScript::scriptChanged(const TTroomScript *roomScript,
 
 		_responseFlag = false;
 		CTrueTalkManager::_v9 = 0;
-		// Deliberate fall-through
+		// Intentional fall-through
 	default:
 		if (roomScript->_scriptId == 115 && id == 103) {
 			switch (getValue(4)) {





More information about the Scummvm-git-logs mailing list