GNU gettext - Bugs: bug #42206, xgettext concatenates lines in C...
You are not allowed to post comments on this tracker with your current authentication level.
bug #42206: xgettext concatenates lines in C files when it shouldn't
Submitter: | Armijn Hemel <armijn> | ||
Submitted: | Sun 27 Apr 2014 04:59:09 PM UTC | ||
Category: | C | Severity: | 3 - Normal |
Item Group: | None | Status: | Not a Bug |
Privacy: | Public | Assigned to: | haible |
Open/Closed: | Closed |
Jump to the original submission
Wed 15 Mar 2023 10:52:35 PM UTC, comment #7: |
Bruno Haible <haible> |
Wed 15 Mar 2023 10:47:20 PM UTC, comment #6: If we would want to treat #if lines correctly, we would need to
|
Bruno Haible <haible> |
Wed 30 Apr 2014 06:42:40 AM UTC, comment #5: Thanks for the background info, perhaps the attached patch might meet your use-case. However, I doubt if it is generally useful, since there is no way to extract the second string (after #else).
|
Daiki Ueno <ueno> |
Mon 28 Apr 2014 07:56:43 AM UTC, comment #4: Thanks for your swift reply. Unfortunately for me that workaround will not work as my use case is a bit different. Please let me explain. I am using xgettext to analyse vast amounts of source code and to extract identifiers that could end up in binaries for fingerprinting. Because xgettext concatenates these two strings fingerprinting (partially) fails. It is not my intention to modify the source code that I analyse.
|
Armijn Hemel <armijn> |
Sun 27 Apr 2014 11:59:14 PM UTC, comment #3: Can't it be easily worked around by modifying the code a bit:
|
Daiki Ueno <ueno> |
Sun 27 Apr 2014 05:01:25 PM UTC, comment #2: and also with 0.18.3. Apologies for the noise. |
Armijn Hemel <armijn> |
Sun 27 Apr 2014 05:00:18 PM UTC, comment #1: I forgot to add:
|
Armijn Hemel <armijn> |
Sun 27 Apr 2014 04:59:09 PM UTC, original submission:
xgettext concatenates lines in C files when it shouldn't. The following snippet is from init/init.c from BusyBox 1.1.0 (around line 770):
|
Armijn Hemel <armijn> |
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 9 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2023-03-15 | haible | Status | None | Not a Bug | |
Assigned to | None | haible | |||
Open/Closed | Open | Closed | |||
2023-03-15 | haible | Attached File | #54494 | Removed | |
2023-03-15 | haible | Attached File | - | Added init2.c, #54493 | |
Attached File | - | Added init2.c, #54494 | |||
2016-11-27 | haible | Category | None | C | |
2014-04-30 | ueno | Attached File | - | Added gettext-cpp-ifelse.patch, #31280 | |
2014-04-27 | armijn | Attached File | - | Added init.c, #31258 |
Powered by Savane 3.13-758e.
Corresponding source code
Given that
I'm not going to make this change.
For the use-case of internationalization, the programmer should restructure his code a bit, so as to move complete function calls into the #if/#else branches.