Commits

Daniele Varrazzo committed 2092122

Identify the name of a PostgreSQL procedure language also when quoted

Comments (0)

Files changed (2)

pygments/lexers/postgres.py

 
 line_re  = re.compile('.*?\n')
 
-language_re = re.compile(r'\s+LANGUAGE\s+(\w+)')
+language_re = re.compile(r"\s+LANGUAGE\s+'?(\w+)'?")
 
 class PostgresLexer(RegexLexer):
     """

tests/examplefiles/postgresql_test.txt

     RETURN 42;
 END
 $x$
-LANGUAGE plpgsql;
+LANGUAGE 'plpgsql';
 
 CREATE FUNCTION pymax (a integer, b integer)
   RETURNS integer