VC warning fixes.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@34610 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Włodzimierz Skiba
2005-06-09 18:37:50 +00:00
parent 08dd04d082
commit cde6d2e7d8
3 changed files with 507 additions and 483 deletions

View File

@@ -7,6 +7,12 @@
/* Copyright: (c) Julian Smart */
/* Licence: wxWindows Licence */
#ifdef __VISUALC__
#pragma warning(push)
#pragma warning(disable:4127) /* warning C4127: conditional expression is constant [about while ( 0 | 1 )] */
#pragma warning(disable:4244) /* warning C4244: '=' : conversion from 'A' to 'B', possible loss of data */
#endif
#define FLEX_SCANNER
#include <stdio.h>
@@ -62,6 +68,10 @@
#endif /* __STDC__ */
#ifdef __VISUALC__
#define YY_USE_PROTOS
#endif
#ifdef __BORLANDC__
#include <io.h>
#define YY_USE_PROTOS
@@ -222,9 +232,9 @@ int yywrap(void) { return 1; }
typedef struct yy_buffer_state *YY_BUFFER_STATE;
#define YY_CHAR unsigned char
// # line 1 "lexer.l"
/* # line 1 "lexer.l" */
#define INITIAL 0
// # line 9 "lexer.l"
/* # line 9 "lexer.l" */
/*
* File: lexer.l
* Description: Lexical analyser for PROLOGIO; can be used with
@@ -278,7 +288,7 @@ static int my_input(void);
#define unput(_c) my_unput(_c)
#endif
// # line 58 "lexer.l"
/* # line 58 "lexer.l" */
/* done after the current pattern has been matched and before the
* corresponding action - sets up yytext
@@ -812,8 +822,8 @@ do_action: /* this label is used only to access EOF actions */
yy_bp = yytext + YY_MORE_ADJ;
goto yy_find_action;
}
break;
}
break;
default:
#ifdef FLEX_DEBUG
@@ -849,8 +859,7 @@ static int yy_get_next_buffer()
int ret_val;
if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
YY_FATAL_ERROR(
"fatal flex scanner internal error--end of buffer missed" );
YY_FATAL_ERROR( "fatal flex scanner internal error--end of buffer missed" );
/* try to read more data */
@@ -1222,7 +1231,7 @@ FILE *file;
b->yy_eof_status = EOF_NOT_SEEN;
}
// # line 108 "lexer.l"
/* # line 108 "lexer.l" */
@@ -1322,3 +1331,6 @@ void wxExprCleanUp()
yy_delete_buffer(yy_current_buffer);
}
#ifdef __VISUALC__
#pragma warning(pop)
#endif

View File

@@ -1,12 +1,18 @@
/* Copyright: (c) Julian Smart */
/* Licence: wxWindows Licence */
/* include platform.h first to get __WIN32__ definition */
#include "wx/platform.h"
#include "wx/setup.h"
#include "wx/deprecated/setup.h"
#if !defined(wxUSE_PROLOGIO) || wxUSE_PROLOGIO
#ifdef __VISUALC__
#pragma warning(push)
#pragma warning(disable:4244) /* warning C4244: '=' : conversion from 'A' to 'B', possible loss of data */
#endif
#if !defined(lint) && 0
static char yysccsid[] = "@(#)yaccpar 1.7 (Berkeley) 09/09/90";
#endif
@@ -539,4 +545,8 @@ yyaccept:
return (0);
}
#ifdef __VISUALC__
#pragma warning(pop)
#endif
#endif /* wxUSE_PROLOGIO */

View File

@@ -464,8 +464,10 @@ update(
} else if (sr > -32768) {
mag = -sr;
state_ptr->sr[0] = base2(mag) - 0x400;
} else
state_ptr->sr[0] = short (0xFC20);
} else {
const unsigned short c = 0xFC20;
state_ptr->sr[0] = short(c);
}
/* DELAY A */
state_ptr->pk[1] = state_ptr->pk[0];