Synced pgc.l with scan.l.
This commit is contained in:
parent
ba8b844f5a
commit
e6851f056a
@ -1060,8 +1060,12 @@ Mon Feb 26 15:22:04 CET 2001
|
|||||||
|
|
||||||
- Fixed misplaced variables FoundInto and QueryIsRule.
|
- Fixed misplaced variables FoundInto and QueryIsRule.
|
||||||
|
|
||||||
Don Mar 29 10:23:05 CEST 2001
|
Thu Mar 29 10:23:05 CEST 2001
|
||||||
|
|
||||||
- Applied bug fix in ecpgtype.h by Adriaan Joubert.
|
- Applied bug fix in ecpgtype.h by Adriaan Joubert.
|
||||||
|
|
||||||
|
Mon Apr 2 10:16:10 CEST 2001
|
||||||
|
|
||||||
|
- Synced scan.l and pgc.l.
|
||||||
- Set ecpg version to 2.8.0.
|
- Set ecpg version to 2.8.0.
|
||||||
- Set library version to 3.2.0.
|
- Set library version to 3.2.0.
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/pgc.l,v 1.77 2001/02/21 18:53:47 tgl Exp $
|
* $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/pgc.l,v 1.78 2001/04/02 08:17:24 meskes Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -335,13 +335,20 @@ cppline {space}*#(.*\\{line_end})*.*
|
|||||||
startlit();
|
startlit();
|
||||||
}
|
}
|
||||||
<xh>{xhstop} {
|
<xh>{xhstop} {
|
||||||
|
long val;
|
||||||
char* endptr;
|
char* endptr;
|
||||||
|
|
||||||
BEGIN(SQL);
|
BEGIN(SQL);
|
||||||
errno = 0;
|
errno = 0;
|
||||||
yylval.ival = strtol(literalbuf, &endptr, 16);
|
val = strtol(literalbuf, &endptr, 16);
|
||||||
if (*endptr != '\0' || errno == ERANGE)
|
if (*endptr != '\0' || errno == ERANGE
|
||||||
|
#ifdef HAVE_LONG_INT_64
|
||||||
|
/* if long > 32 bits, check for overflow of int4 */
|
||||||
|
|| val != (long) ((int32) val)
|
||||||
|
#endif
|
||||||
|
)
|
||||||
mmerror(ET_ERROR, "Bad hexadecimal integer input");
|
mmerror(ET_ERROR, "Bad hexadecimal integer input");
|
||||||
|
yylval.ival = val;
|
||||||
return ICONST;
|
return ICONST;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -498,16 +505,23 @@ cppline {space}*#(.*\\{line_end})*.*
|
|||||||
return PARAM;
|
return PARAM;
|
||||||
}
|
}
|
||||||
<C,SQL>{integer} {
|
<C,SQL>{integer} {
|
||||||
|
long val;
|
||||||
char* endptr;
|
char* endptr;
|
||||||
|
|
||||||
errno = 0;
|
errno = 0;
|
||||||
yylval.ival = strtol((char *)yytext, &endptr,10);
|
val = strtol((char *)yytext, &endptr,10);
|
||||||
if (*endptr != '\0' || errno == ERANGE)
|
if (*endptr != '\0' || errno == ERANGE
|
||||||
|
#ifdef HAVE_LONG_INT_64
|
||||||
|
/* if long > 32 bits, check for overflow of int4 */
|
||||||
|
|| val != (long) ((int32) val)
|
||||||
|
#endif
|
||||||
|
)
|
||||||
{
|
{
|
||||||
errno = 0;
|
errno = 0;
|
||||||
yylval.str = mm_strdup((char*)yytext);
|
yylval.str = mm_strdup((char*)yytext);
|
||||||
return FCONST;
|
return FCONST;
|
||||||
}
|
}
|
||||||
|
yylval.ival = val;
|
||||||
return ICONST;
|
return ICONST;
|
||||||
}
|
}
|
||||||
<SQL>{ip} {
|
<SQL>{ip} {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user