Update prebuilt Clang to match Android kernel.
Bug: 132428451
Change-Id: I8f6e2cb23f381fc0c02ddea99b867e58e925e5be
diff --git a/linux-x64/clang/include/llvm/Demangle/StringView.h b/linux-x64/clang/include/llvm/Demangle/StringView.h
index a89deda..ceb6c79 100644
--- a/linux-x64/clang/include/llvm/Demangle/StringView.h
+++ b/linux-x64/clang/include/llvm/Demangle/StringView.h
@@ -1,22 +1,25 @@
//===--- StringView.h -------------------------------------------*- C++ -*-===//
//
-// The LLVM Compiler Infrastructure
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
+//===----------------------------------------------------------------------===//
//
+// FIXME: Use std::string_view instead when we support C++17.
//
-// This file contains a limited version of LLVM's StringView class. It is
-// copied here so that LLVMDemangle need not take a dependency on LLVMSupport.
//===----------------------------------------------------------------------===//
-#ifndef LLVM_DEMANGLE_STRINGVIEW_H
-#define LLVM_DEMANGLE_STRINGVIEW_H
+#ifndef DEMANGLE_STRINGVIEW_H
+#define DEMANGLE_STRINGVIEW_H
+#include "DemangleConfig.h"
#include <algorithm>
#include <cassert>
#include <cstring>
+DEMANGLE_NAMESPACE_BEGIN
+
class StringView {
const char *First;
const char *Last;
@@ -43,7 +46,7 @@
if (FindBegin < size()) {
// Just forward to memchr, which is faster than a hand-rolled loop.
if (const void *P = ::memchr(First + FindBegin, C, size() - FindBegin))
- return static_cast<const char *>(P) - First;
+ return size_t(static_cast<const char *>(P) - First);
}
return npos;
}
@@ -118,4 +121,6 @@
std::equal(LHS.begin(), LHS.end(), RHS.begin());
}
+DEMANGLE_NAMESPACE_END
+
#endif