bugGNU gettext - Bugs: bug #33451, xgettext ignores translation hints...


You are not allowed to post comments on this tracker with your current authentication level.

bug #33451: xgettext ignores translation hints when source contains two line breaks

Submitted by:  None
Submitted on:  Wed 01 Jun 2011 10:07:53 AM UTC  
Category: PHPSeverity: 3 - Normal
Item Group: NoneStatus: Duplicate
Privacy: PublicAssigned to: Daiki Ueno <ueno>
Open/Closed: Closed

Mon 01 Dec 2014 07:52:01 AM UTC, comment #1:


Daiki Ueno <ueno>
Project AdministratorIn charge of this item.
Wed 01 Jun 2011 10:07:53 AM UTC, original submission:

$ xgettext --version
xgettext (GNU gettext-tools) 0.18.1

Note the line breaks in the following source code
1) after _(
2) before _(
3) before and after _(

$ cat bug.php

echo /* I18N: hint one */ _(
'text one');

echo /* I18N: hint two */
_('text two');

echo /* I18N: hint three */
'text three');


$ xgettext --language=PHP bug.php --add-comments=I18N --output=-

#. I18N: hint one
#: bug.php:4
msgid "text one"
msgstr ""

#. I18N: hint two
#: bug.php:7
msgid "text two"
msgstr ""

#: bug.php:11
msgid "text three"
msgstr ""

It seems that xgettext correctly matches the translation hints in the first two cases, but not the third.

Greg Roach



No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by haible (Updated the item)
  • -unavailable- added by ueno (Posted a comment)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 27 Nov 2016 01:13:06 AM UTChaibleCategoryNone=>PHP
      Assigned toNone=>ueno
    Mon 01 Dec 2014 07:52:01 AM UTCuenoStatusNone=>Duplicate

    Back to the top

    Powered by Savane 3.1-cleanup1