Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clang adds initial newline for files that start with UTF-8 BOM. #18127

Closed
llvmbot opened this issue Oct 31, 2013 · 1 comment
Closed

Clang adds initial newline for files that start with UTF-8 BOM. #18127

llvmbot opened this issue Oct 31, 2013 · 1 comment
Labels
bugzilla Issues migrated from bugzilla clang-format

Comments

@llvmbot
Copy link
Collaborator

llvmbot commented Oct 31, 2013

Bugzilla Link 17753
Resolution FIXED
Resolved on Nov 13, 2013 08:04
Version trunk
OS Linux
Reporter LLVM Bugzilla Contributor

Extended Description

When formatting a file that contains a UTF-8 BOM the result will include a newline character.

Hexdump before:
0000000: efbb bf23 696e 636c 7564 6520 3c69 6f73 ...#include <ios
0000010: 7472 6561 6d3e 0a0a 7573 696e 6720 6e61 tream>..using na

Hexdump after:
0000000: efbb bf0a 2369 6e63 6c75 6465 203c 696f ....#include <io
0000010: 7374 7265 616d 3e0a 0a75 7369 6e67 206e stream>..using n

Tested on revision 193745 on Linux, Debian Testing.

@llvmbot
Copy link
Collaborator Author

llvmbot commented Nov 13, 2013

Fixed in r194576.

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 9, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla clang-format
Projects
None yet
Development

No branches or pull requests

1 participant