This adds coverage for expressions of these forms
absl::Duration d2, d1; d2 = absl::Seconds(d1 / absl::Seconds(1)); d2 = absl::Seconds(absl::FDivDuration(d1, absl::Seconds(1)));
Paths
| Differential D59183
[clang-tidy] Expand cases covered by the abseil-duration-unnecessary-conversion check ClosedPublic Authored by hwright on Mar 9 2019, 6:17 PM.
Details Summary This adds coverage for expressions of these forms absl::Duration d2, d1; d2 = absl::Seconds(d1 / absl::Seconds(1)); d2 = absl::Seconds(absl::FDivDuration(d1, absl::Seconds(1)));
Diff Detail
Event Timeline
hwright marked 4 inline comments as done. Comment ActionsAddressed reviewer comments
This revision is now accepted and ready to land.Mar 14 2019, 1:45 AM Closed by commit rCTE356141: [clang-tidy] Add additional patterns to the abseil-duration-unnecessary… (authored by hwright). · Explain WhyMar 14 2019, 6:40 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 190613 clang-tidy/abseil/DurationUnnecessaryConversionCheck.cpp
docs/clang-tidy/checks/abseil-duration-unnecessary-conversion.rst
test/clang-tidy/Inputs/absl/time/time.h
test/clang-tidy/abseil-duration-unnecessary-conversion.cpp |
could you add a few comment briefly describing these matchers?