aboutsummaryrefslogtreecommitdiffstats
path: root/unittests/IR/UseTest.cpp
diff options
context:
space:
mode:
authorStephen Hines <srhines@google.com>2015-04-01 18:49:24 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2015-04-01 18:49:26 +0000
commit3fa16bd6062e23bcdb82ed4dd965674792e6b761 (patch)
tree9348fc507292f7e8715d22d64ce5a32131b4f875 /unittests/IR/UseTest.cpp
parentbeed47390a60f6f0c77532b3d3f76bb47ef49423 (diff)
parentebe69fe11e48d322045d5949c83283927a0d790b (diff)
downloadexternal_llvm-3fa16bd6062e23bcdb82ed4dd965674792e6b761.zip
external_llvm-3fa16bd6062e23bcdb82ed4dd965674792e6b761.tar.gz
external_llvm-3fa16bd6062e23bcdb82ed4dd965674792e6b761.tar.bz2
Merge "Update aosp/master LLVM for rebase to r230699."
Diffstat (limited to 'unittests/IR/UseTest.cpp')
-rw-r--r--unittests/IR/UseTest.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/unittests/IR/UseTest.cpp b/unittests/IR/UseTest.cpp
index 3f33ca6..d9d20af 100644
--- a/unittests/IR/UseTest.cpp
+++ b/unittests/IR/UseTest.cpp
@@ -9,10 +9,10 @@
#include "llvm/AsmParser/Parser.h"
#include "llvm/IR/Function.h"
+#include "llvm/IR/Instructions.h"
#include "llvm/IR/LLVMContext.h"
#include "llvm/IR/Module.h"
#include "llvm/IR/User.h"
-#include "llvm/IR/Instructions.h"
#include "llvm/Support/Format.h"
#include "llvm/Support/SourceMgr.h"
#include "gtest/gtest.h"
@@ -50,7 +50,7 @@ TEST(UseTest, sort) {
});
unsigned I = 0;
for (User *U : X.users()) {
- snprintf(vnbuf, sizeof(vnbuf), "v%u", I++);
+ format("v%u", I++).snprint(vnbuf, sizeof(vnbuf));
EXPECT_EQ(vnbuf, U->getName());
}
ASSERT_EQ(8u, I);
@@ -60,7 +60,7 @@ TEST(UseTest, sort) {
});
I = 0;
for (User *U : X.users()) {
- snprintf(vnbuf, sizeof(vnbuf), "v%u", (7 - I++));
+ format("v%u", (7 - I++)).snprint(vnbuf, sizeof(vnbuf));
EXPECT_EQ(vnbuf, U->getName());
}
ASSERT_EQ(8u, I);
@@ -95,7 +95,7 @@ TEST(UseTest, reverse) {
});
unsigned I = 0;
for (User *U : X.users()) {
- snprintf(vnbuf, sizeof(vnbuf), "v%u", I++);
+ format("v%u", I++).snprint(vnbuf, sizeof(vnbuf));
EXPECT_EQ(vnbuf, U->getName());
}
ASSERT_EQ(8u, I);
@@ -103,7 +103,7 @@ TEST(UseTest, reverse) {
X.reverseUseList();
I = 0;
for (User *U : X.users()) {
- snprintf(vnbuf, sizeof(vnbuf), "v%u", (7 - I++));
+ format("v%u", (7 - I++)).snprint(vnbuf, sizeof(vnbuf));
EXPECT_EQ(vnbuf, U->getName());
}
ASSERT_EQ(8u, I);