[PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check
Richard via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 25 04:02:52 PST 2016
LegalizeAdulthood created this revision.
LegalizeAdulthood added a reviewer: alexfh.
LegalizeAdulthood added a subscriber: cfe-commits.
This check examines string literals and looks for those that could be more directly expressed as a raw string literal.
Example:
```
char const *const BackSlash{"goink\\frob"};
```
becomes:
```
char const *const BackSlash{R"(goink\frob)"};
```
Addresses PR24444
http://reviews.llvm.org/D16529
Files:
clang-tidy/modernize/CMakeLists.txt
clang-tidy/modernize/ModernizeTidyModule.cpp
clang-tidy/modernize/RawStringLiteralCheck.cpp
clang-tidy/modernize/RawStringLiteralCheck.h
docs/clang-tidy/checks/list.rst
docs/clang-tidy/checks/modernize-raw-string-literal.rst
test/clang-tidy/modernize-raw-string-literal.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D16529.45851.patch
Type: text/x-patch
Size: 11331 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160125/40034f2a/attachment.bin>
More information about the cfe-commits
mailing list