summaryrefslogtreecommitdiffstats
path: root/gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp
diff options
context:
space:
mode:
authorpatrick <patrick@openbsd.org>2017-01-14 19:55:43 +0000
committerpatrick <patrick@openbsd.org>2017-01-14 19:55:43 +0000
commitbd3306aecb3a15e8967143b8cdbbccf2b1b19b74 (patch)
tree309a8132b44564b9e634c0da6815187ce8eab27c /gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp
parentkillp -a should not kill the window if only one pane. (diff)
downloadwireguard-openbsd-bd3306aecb3a15e8967143b8cdbbccf2b1b19b74.tar.xz
wireguard-openbsd-bd3306aecb3a15e8967143b8cdbbccf2b1b19b74.zip
Import LLVM 3.9.1 including clang and lld.
Diffstat (limited to 'gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp')
-rw-r--r--gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp b/gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp
index 15f1696cbe9..c4beef24946 100644
--- a/gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp
+++ b/gnu/llvm/tools/clang/lib/Index/CommentToXML.cpp
@@ -592,9 +592,8 @@ void getSourceTextOfDeclaration(const DeclInfo *ThisDecl,
void CommentASTToXMLConverter::formatTextOfDeclaration(
const DeclInfo *DI, SmallString<128> &Declaration) {
- // FIXME. formatting API expects null terminated input string.
- // There might be more efficient way of doing this.
- std::string StringDecl = Declaration.str();
+ // Formatting API expects null terminated input string.
+ StringRef StringDecl(Declaration.c_str(), Declaration.size());
// Formatter specific code.
// Form a unique in memory buffer name.