summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/Support/ARMAttributeParser.cpp
diff options
context:
space:
mode:
authorSam Parker <sam.parker@arm.com>2017-02-01 12:58:57 +0000
committerSam Parker <sam.parker@arm.com>2017-02-01 12:58:57 +0000
commit0085af67720c087de95d02f74bfb9324da72c80b (patch)
tree02bb7f26edce49c502f25c6da040a833a693a71a /llvm/unittests/Support/ARMAttributeParser.cpp
parentb7a6ea304999bb509267abb3b379a9e7bd40849a (diff)
downloadbcm5719-llvm-0085af67720c087de95d02f74bfb9324da72c80b.tar.gz
bcm5719-llvm-0085af67720c087de95d02f74bfb9324da72c80b.zip
[ARM] const cast fix for ARMAttributeParser test
GCC 4.8 produced a cast qualifier warning, so replaced with C++ style const cast. llvm-svn: 293764
Diffstat (limited to 'llvm/unittests/Support/ARMAttributeParser.cpp')
-rw-r--r--llvm/unittests/Support/ARMAttributeParser.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/unittests/Support/ARMAttributeParser.cpp b/llvm/unittests/Support/ARMAttributeParser.cpp
index 82cbcd1fc15..c2df6537ff6 100644
--- a/llvm/unittests/Support/ARMAttributeParser.cpp
+++ b/llvm/unittests/Support/ARMAttributeParser.cpp
@@ -26,12 +26,13 @@ struct AttributeSection {
};
bool testBuildAttr(unsigned Tag, unsigned Value,
- unsigned ExpectedTag, unsigned ExpectedValue) {
+ unsigned ExpectedTag, unsigned ExpectedValue) {
std::string buffer;
raw_string_ostream OS(buffer);
AttributeSection Section(Tag, Value);
Section.write(OS);
- ArrayRef<uint8_t> Bytes((uint8_t*)OS.str().c_str(), OS.str().size());
+ ArrayRef<uint8_t> Bytes(
+ reinterpret_cast<const uint8_t*>(OS.str().c_str()), OS.str().size());
ARMAttributeParser Parser;
Parser.Parse(Bytes, true);
OpenPOWER on IntegriCloud