summaryrefslogtreecommitdiffstats
path: root/clang/lib/Format/Encoding.h
Commit message (Collapse)AuthorAgeFilesLines
* Fix crash in getStringSplit.Alexander Kornienko2013-11-261-3/+5
| | | | | | | | | | | | | | | | Summary: getStringSplit used to crash, when trying to split a long string literal containing both printable and unprintable multi-byte UTF-8 characters. Reviewers: djasper, klimek Reviewed By: djasper CC: cfe-commits, klimek Differential Revision: http://llvm-reviews.chandlerc.com/D2268 llvm-svn: 195728
* Handle zero-width and double-width characters in string literals and comments.Alexander Kornienko2013-09-051-0/+32
| | | | | | | | | | | | | | | | | | Summary: Count column width instead of the number of code points. This also includes correct handling of tabs inside string literals and comments (with an exception of multiline string literals/comments, where tabs are present before the first escaped newline). Reviewers: djasper, klimek Reviewed By: klimek CC: cfe-commits, klimek Differential Revision: http://llvm-reviews.chandlerc.com/D1601 llvm-svn: 190052
* Reformat clang-format's source files after r185822 and others.Daniel Jasper2013-07-081-11/+9
| | | | llvm-svn: 185823
* UTF-8 support for clang-format.Alexander Kornienko2013-06-051-0/+114
Summary: Detect if the file is valid UTF-8, and if this is the case, count code points instead of just using number of bytes in all (hopefully) places, where number of columns is needed. In particular, use the new FormatToken.CodePointCount instead of TokenLength where appropriate. Changed BreakableToken implementations to respect utf-8 character boundaries when in utf-8 mode. Reviewers: klimek, djasper Reviewed By: djasper CC: cfe-commits, rsmith, gribozavr Differential Revision: http://llvm-reviews.chandlerc.com/D918 llvm-svn: 183312
OpenPOWER on IntegriCloud