]> git.ipfire.org Git - thirdparty/gettext.git/commit
xgettext: Handle newlines in Lua long bracket literal strings correctly.
authorBruno Haible <bruno@clisp.org>
Thu, 22 Aug 2019 14:36:59 +0000 (16:36 +0200)
committerBruno Haible <bruno@clisp.org>
Thu, 22 Aug 2019 14:36:59 +0000 (16:36 +0200)
commit5443a27e2b4afafe57b1dd8f518cd013dc0ca0a1
treef3d006a85632b3ed2e3e4b5612da75a1b7406e09
parent7643c58c13761bf0062c73d3114d4243250e8be9
xgettext: Handle newlines in Lua long bracket literal strings correctly.

Reported by Frans de Jonge <fransdejonge@gmail.com>
at <https://savannah.gnu.org/bugs/?56794>.

* gettext-tools/src/x-lua.c (phase3_get): Test for EOF first. After an opening
long bracket, swallow one newline.
* gettext-tools/tests/xgettext-lua-1: Add tests for newlines in long brackets.
* gettext-tools/tests/xgettext-lua-2: Update comment.
gettext-tools/src/x-lua.c
gettext-tools/tests/xgettext-lua-1
gettext-tools/tests/xgettext-lua-2