diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2002-07-30 16:33:08 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2002-07-30 16:33:08 +0000 |
commit | 9f1fc1080e91005cad96f84463e2392604823024 (patch) | |
tree | 6ef13d6e0f5bd9efc7c4aad4ec7953f8c341a2c1 /contrib | |
parent | 74780590d81150712e7971a9a6af24c0ef78842f (diff) | |
download | postgresql-9f1fc1080e91005cad96f84463e2392604823024.tar.gz postgresql-9f1fc1080e91005cad96f84463e2392604823024.zip |
Since we're depending on %option noyywrap in the main scanner now,
we may as well use it in all our flex files. Make all the flex files
have a consistent set of options.
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/cube/cubescan.l | 8 | ||||
-rw-r--r-- | contrib/seg/segscan.l | 8 | ||||
-rw-r--r-- | contrib/tsearch/parser.l | 11 |
3 files changed, 18 insertions, 9 deletions
diff --git a/contrib/cube/cubescan.l b/contrib/cube/cubescan.l index e10e7faad8f..d1aed4c75ae 100644 --- a/contrib/cube/cubescan.l +++ b/contrib/cube/cubescan.l @@ -10,8 +10,6 @@ #include "cubeparse.h" #include "buffer.h" -#define YY_NO_UNPUT 1 -#undef yywrap /* flex screws a couple symbols when used with the -P otion; fix those */ #define YY_DECL int cube_yylex YY_PROTO(( void )); \ @@ -28,6 +26,12 @@ int cube_yylex YY_PROTO(( void )) void cube_flush_scanner_buffer(void); %} +%option 8bit +%option never-interactive +%option nounput +%option noyywrap + + n [0-9]+ integer [+-]?{n} real [+-]?({n}\.{n}?)|(\.{n}) diff --git a/contrib/seg/segscan.l b/contrib/seg/segscan.l index ea9032685a9..787fe28843c 100644 --- a/contrib/seg/segscan.l +++ b/contrib/seg/segscan.l @@ -8,8 +8,6 @@ #include "segparse.h" #include "buffer.h" -#define YY_NO_UNPUT 1 -#undef yywrap /* flex screws a couple symbols when used with the -P otion; fix those */ #define YY_DECL int seg_yylex YY_PROTO(( void )); \ @@ -27,6 +25,12 @@ int seg_yylex YY_PROTO(( void )) void seg_flush_scanner_buffer(void); %} +%option 8bit +%option never-interactive +%option nounput +%option noyywrap + + range (\.\.)(\.)? plumin (\'\+\-\')|(\(\+\-)\) integer [+-]?[0-9]+ diff --git a/contrib/tsearch/parser.l b/contrib/tsearch/parser.l index 66b8cf56dfe..6081fd4c7be 100644 --- a/contrib/tsearch/parser.l +++ b/contrib/tsearch/parser.l @@ -50,9 +50,14 @@ int bytestoread = 0; /* for limiting read from filehandle */ } \ } -#define YY_NO_UNPUT %} +%option 8bit +%option never-interactive +%option nounput +%option noyywrap + + /* parser's state for parsing defis-word */ %x DELIM /* parser's state for parsing URL*/ @@ -289,10 +294,6 @@ ftp"://" { %% -int tsearch_yywrap(void) { - return 1; -} - /* clearing after parsing from string */ void end_parse() { if (s) { free(s); s=NULL; } |