Re: [HACKERS] Lex and things...
| От | Leon |
|---|---|
| Тема | Re: [HACKERS] Lex and things... |
| Дата | |
| Msg-id | 37C2A782.BA6FC0A2@udmnet.ru обсуждение исходный текст |
| Ответ на | RE: [HACKERS] Lex and things... ("Ansley, Michael" <Michael.Ansley@intec.co.za>) |
| Список | pgsql-hackers |
Ansley, Michael wrote:
>
> As far as I understand it, the MAX_PARSE_BUFFER limit only applies if char
> parsestring[] is used, not if char *parsestring is used. This is the whole
> reason for using flex. And scan.l is set up to compile using char
> *parsestring, not char parsestring[].
>
What is defined explicitly:
#ifdef YY_READ_BUF_SIZE
#undef YY_READ_BUF_SIZE
#endif
#define YY_READ_BUF_SIZE MAX_PARSE_BUFFER
(these strings are repeated twice :)
...
char literal[MAX_PARSE_BUFFER];
...
<xq>{xqliteral} { if ((llen+yyleng) > (MAX_PARSE_BUFFER - 1)) elog(ERROR,"quoted
stringparse buffer of %d chars
exceeded",MAX_PARSE_BUFFER); memcpy(literal+llen, yytext, yyleng+1); llen += yyleng;
}
Seems that limits are everywhere ;)
--
Leon.
В списке pgsql-hackers по дате отправления: