Commit b871426f authored by George Burgess IV's avatar George Burgess IV Committed by Commit Bot

fix instances of bugprone-argument-comment

This new clang-tidy check complains when param names /*in_comments=*/
don't match up with the actual parameter name they're being passed to.
Sometimes this is benign, other times, actual bugs are found.

Bug: 1136209
Change-Id: Ida6c0246026bc6aa937f42db7596ef4b902b2a1b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2458874Reviewed-by: default avatarKent Tamura <tkent@chromium.org>
Commit-Queue: George Burgess <gbiv@chromium.org>
Cr-Commit-Position: refs/heads/master@{#815508}
parent d7c5c1d5
...@@ -11,7 +11,7 @@ namespace blink { ...@@ -11,7 +11,7 @@ namespace blink {
TEST(StepRangeTest, ClampValueWithOutStepMatchedValue) { TEST(StepRangeTest, ClampValueWithOutStepMatchedValue) {
// <input type=range value=200 min=0 max=100 step=1000> // <input type=range value=200 min=0 max=100 step=1000>
StepRange step_range(Decimal(200), Decimal(0), Decimal(100), true, StepRange step_range(Decimal(200), Decimal(0), Decimal(100), true,
/*has_reversed_range=*/false, Decimal(1000), /*supports_reversed_range=*/false, Decimal(1000),
StepRange::StepDescription()); StepRange::StepDescription());
EXPECT_EQ(Decimal(100), step_range.ClampValue(Decimal(200))); EXPECT_EQ(Decimal(100), step_range.ClampValue(Decimal(200)));
...@@ -21,7 +21,7 @@ TEST(StepRangeTest, ClampValueWithOutStepMatchedValue) { ...@@ -21,7 +21,7 @@ TEST(StepRangeTest, ClampValueWithOutStepMatchedValue) {
TEST(StepRangeTest, StepSnappedMaximum) { TEST(StepRangeTest, StepSnappedMaximum) {
// <input type=number value="1110" max=100 step="20"> // <input type=number value="1110" max=100 step="20">
StepRange step_range(Decimal::FromDouble(1110), Decimal(0), Decimal(100), StepRange step_range(Decimal::FromDouble(1110), Decimal(0), Decimal(100),
true, /*has_reversed_range=*/false, Decimal(20), true, /*supports_reversed_range=*/false, Decimal(20),
StepRange::StepDescription()); StepRange::StepDescription());
EXPECT_EQ(Decimal(90), step_range.StepSnappedMaximum()); EXPECT_EQ(Decimal(90), step_range.StepSnappedMaximum());
...@@ -30,7 +30,7 @@ TEST(StepRangeTest, StepSnappedMaximum) { ...@@ -30,7 +30,7 @@ TEST(StepRangeTest, StepSnappedMaximum) {
// value="8624024784918570374158793713225864658725102756338798521486349461900449498315865014065406918592181034633618363349807887404915072776534917803019477033072906290735591367789665757384135591225430117374220731087966" // value="8624024784918570374158793713225864658725102756338798521486349461900449498315865014065406918592181034633618363349807887404915072776534917803019477033072906290735591367789665757384135591225430117374220731087966"
// min=0 max=100 step="18446744073709551575"> // min=0 max=100 step="18446744073709551575">
StepRange step_range2(Decimal::FromDouble(8.62402e+207), Decimal(0), StepRange step_range2(Decimal::FromDouble(8.62402e+207), Decimal(0),
Decimal(100), true, /*has_reversed_range=*/false, Decimal(100), true, /*supports_reversed_range=*/false,
Decimal::FromDouble(1.84467e+19), Decimal::FromDouble(1.84467e+19),
StepRange::StepDescription()); StepRange::StepDescription());
EXPECT_FALSE(step_range2.StepSnappedMaximum().IsFinite()); EXPECT_FALSE(step_range2.StepSnappedMaximum().IsFinite());
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment