[Lldb-commits] [PATCH] D62626: Remove length modifier when using assignment suppression in TimerTest
António Afonso via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Wed May 29 13:32:22 PDT 2019
aadsm created this revision.
aadsm added a reviewer: xiaobai.
Herald added subscribers: lldb-commits, krytarowski.
Herald added a project: LLDB.
xiaobai accepted this revision.
xiaobai added a comment.
This revision is now accepted and ready to land.
lgtm
This is useless and it's giving warnings in the build bots:
/home/motus/netbsd8/netbsd8/llvm/tools/lldb/unittests/Utility/TimerTest.cpp:67:43: warning: use of assignment suppression and length modifier together in gnu_scanf format [-Wformat=]
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D62626
Files:
lldb/unittests/Utility/TimerTest.cpp
Index: lldb/unittests/Utility/TimerTest.cpp
===================================================================
--- lldb/unittests/Utility/TimerTest.cpp
+++ lldb/unittests/Utility/TimerTest.cpp
@@ -62,7 +62,7 @@
Timer::DumpCategoryTimes(&ss);
double seconds1, seconds2;
ASSERT_EQ(2, sscanf(ss.GetData(),
- "%lf sec (total: %*lfs; child: %*lfs; count: %*d) for "
+ "%lf sec (total: %*fs; child: %*fs; count: %*d) for "
"CAT1%*[\n ]%lf sec for CAT2",
&seconds1, &seconds2))
<< "String: " << ss.GetData();
@@ -98,7 +98,7 @@
ASSERT_EQ(
6, sscanf(ss.GetData(),
"%lf sec (total: %lfs; child: %lfs; count: %d) for CAT1%*[\n ]"
- "%lf sec (total: %*lfs; child: %*lfs; count: %d) for CAT2",
+ "%lf sec (total: %*fs; child: %*fs; count: %d) for CAT2",
&seconds1, &total1, &child1, &count1, &seconds2, &count2))
<< "String: " << ss.GetData();
EXPECT_NEAR(total1 - child1, seconds1, 0.002);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D62626.202046.patch
Type: text/x-patch
Size: 1067 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20190529/90d6efde/attachment.bin>
More information about the lldb-commits
mailing list