mirror of
https://github.com/postgres/postgres.git
synced 2025-12-07 12:02:30 +03:00
Improve lexer's error reporting. You get the whole token mentioned now
in parse error messages, not just the part scanned by the last flex rule. For example, select "foo" "bar"; used to draw ERROR: parser: parse error at or near """ which was rather unhelpful. Now it gives ERROR: parser: parse error at or near ""bar"" Also, error messages concerning bitstring literals and suchlike will quote the source text at you, not the processed internal form of the literal.
This commit is contained in:
@@ -17,7 +17,7 @@ SELECT 'first line'
|
||||
' - next line' /* this comment is not allowed here */
|
||||
' - third line'
|
||||
AS "Illegal comment within continuation";
|
||||
ERROR: parser: parse error at or near "'"
|
||||
ERROR: parser: parse error at or near "' - third line'"
|
||||
--
|
||||
-- test conversions between various string types
|
||||
--
|
||||
|
||||
Reference in New Issue
Block a user