From e154e654f1e046a4d60e09d3ef87d1cf9c3ae6ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Konopacki?= Date: Mon, 13 Aug 2012 01:26:36 +0200 Subject: Reduced amount of warnings in CBot library Changed most of C-style casting to C++ casting Commented unused variables --- src/CBot/CBotToken.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/CBot/CBotToken.cpp') diff --git a/src/CBot/CBotToken.cpp b/src/CBot/CBotToken.cpp index d4973e9..c6e65e7 100644 --- a/src/CBot/CBotToken.cpp +++ b/src/CBot/CBotToken.cpp @@ -217,12 +217,12 @@ bool Char2InList(const char c, const char cc, const char* list) } } -static char* sep1 = " \r\n\t,:()[]{}-+*/=;>!~^|&%."; // operational separators -static char* num = "0123456789"; // point (single) is tested separately -static char* hexnum = "0123456789ABCDEFabcdef"; -static char* nch = "\"\r\n\t"; // forbidden in chains +static char sep1[] = " \r\n\t,:()[]{}-+*/=;>!~^|&%."; // operational separators +static char num[] = "0123456789"; // point (single) is tested separately +static char hexnum[] = "0123456789ABCDEFabcdef"; +static char nch[] = "\"\r\n\t"; // forbidden in chains //static char* duo = "+=-=*=/===!=<=>=++--///**/||&&"; // double operators @@ -382,7 +382,7 @@ bis: CBotToken* CBotToken::CompileTokens(const char* program, int& error) { CBotToken *nxt, *prv, *tokenbase; - char* p = (char*) program; + char* p = const_cast ( program); int pos = 0; error = 0; -- cgit v1.2.3-1-g7c22