Compile fixes for gcc -Wall
This commit is contained in:
parent
0718e45c24
commit
d7c5ead6a1
12 changed files with 27 additions and 24 deletions
|
|
@ -183,7 +183,7 @@ void TPpContext::InitAtomTable()
|
|||
}
|
||||
|
||||
// Add multiple character scanner tokens :
|
||||
for (int ii = 0; ii < sizeof(tokens)/sizeof(tokens[0]); ii++)
|
||||
for (size_t ii = 0; ii < sizeof(tokens)/sizeof(tokens[0]); ii++)
|
||||
AddAtomFixed(tokens[ii].str, tokens[ii].val);
|
||||
|
||||
nextAtom = PpAtomLast;
|
||||
|
|
|
|||
|
|
@ -82,7 +82,10 @@ NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||
|
||||
#include "../ParseHelper.h"
|
||||
|
||||
#pragma warning(disable : 4127)
|
||||
/* windows only pragma */
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(disable : 4127)
|
||||
#endif
|
||||
|
||||
namespace glslang {
|
||||
|
||||
|
|
|
|||
|
|
@ -440,7 +440,7 @@ int TPpContext::tStringInput::scan(TPpToken* ppToken)
|
|||
const unsigned remainderMaxInt = 0xFFFFFFFFu - 10 * oneTenthMaxInt;
|
||||
for (int i = 0; i < numericLen; i++) {
|
||||
ch = ppToken->name[i] - '0';
|
||||
if ((ival > oneTenthMaxInt) || (ival == oneTenthMaxInt && ch > remainderMaxInt)) {
|
||||
if ((ival > oneTenthMaxInt) || (ival == oneTenthMaxInt && (unsigned)ch > remainderMaxInt)) {
|
||||
pp->parseContext.ppError(ppToken->loc, "numeric literal too big", "", "");
|
||||
ival = 0xFFFFFFFFu;
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ TPpContext::Symbol* TPpContext::NewSymbol(int atom)
|
|||
{
|
||||
Symbol* lSymb;
|
||||
char* pch;
|
||||
int ii;
|
||||
size_t ii;
|
||||
|
||||
lSymb = (Symbol *) mem_Alloc(pool, sizeof(Symbol));
|
||||
lSymb->atom = atom;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue