commands.cxx

changeset 67
0a202714eea4
parent 65
ec04357f5bb9
child 68
588cc27e84bb
--- a/commands.cxx	Wed Dec 19 03:27:15 2012 +0200
+++ b/commands.cxx	Wed Dec 19 04:20:02 2012 +0200
@@ -159,11 +159,11 @@
 // Get command type by name
 int GetCommandType (str t) {
 	t = t.tolower();
-	return	!t.compare ("int") ? TYPE_INT :
-		!t.compare ("float") ? TYPE_FLOAT :
-		!t.compare ("str") ? TYPE_STRING :
-		!t.compare ("void") ? TYPE_VOID :
-		!t.compare ("bool") ? TYPE_BOOL : -1;
+	return	(t == "int") ? TYPE_INT :
+			(t == "float") ? TYPE_FLOAT :
+			(t == "str") ? TYPE_STRING :
+			(t == "void") ? TYPE_VOID :
+			(t == "bool") ? TYPE_BOOL : -1;
 }
 
 // ============================================================================

mercurial