Georg Brandl committed eb6fdc9 Merge

Merged in dvarrazzo/pygments-postgres (pull request #19)

  • Participants
  • Parent commits 115a402, a2bde5e

Comments (0)

Files changed (2)

File pygments/lexers/

 re_error = re.compile(r'(ERROR|FATAL):')
 re_message = re.compile(
-    r'FATAL|HINT|DETAIL|LINE [0-9]+):)(.*?\n)')
+    r'FATAL|HINT|DETAIL|CONTEXT|LINE [0-9]+):)(.*?\n)')
 def lookahead(x):
     """Wrap an iterator and allow pushing back an item."""

File tests/examplefiles/psql_session.txt

 regression=# select foo;
 ERROR:  column "foo" does not exist
+CONTEXT:  PL/pgSQL function "test1" while casting return value to function's return type
 LINE 1: select foo;
 regression=# \q