]> 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>
Mon, 13 Apr 2020 11:09:24 +0000 (13:09 +0200)
commit78dca0dae51ff358f43a05765fa70d76f55b0bbd
treed7c3f06f5fa38fcf5c919dc63c4c0600c3850f5a
parentf3400e323262b10191148c6c607eb3c46b49746c
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