[Bug c/88424] New: Inserts newlines when preserving comments for a file using Windows newlines
reiter.christoph at gmail dot com
gcc-bugzilla@gcc.gnu.org
Sun Dec 9 18:16:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88424
Bug ID: 88424
Summary: Inserts newlines when preserving comments for a file
using Windows newlines
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: reiter.christoph at gmail dot com
Target Milestone: ---
gcc --version
gcc (Debian 8.2.0-11) 8.2.0
When preprocessing a file which uses Windows newlines without discarding
comments (The -C option) then gcc inserts an extra newline after each line in
comments:
* Write the following to test.c and make sure it uses Windows newlines
/**
* Foo-
* bar-
* quux
*/
int main() {
return 0;
}
* Execute "gcc -C -E test.c"
3) Expected (this is what clang produces):
[...]
/**
* Foo-
* bar-
* quux
*/
int main() {
return 0;
}
* Actual:
/**
* Foo-
* bar-
* quux
*/
# 6 "test.c"
int main() {
return 0;
}
More information about the Gcc-bugs
mailing list