mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-22 15:04:44 +01:00
clang-tidy: Add performance-type-promotion-in-math-fn
check
https://clang.llvm.org/extra/clang-tidy/checks/performance/type-promotion-in-math-fn.html
This commit is contained in:
parent
7e975e6cf8
commit
2400437230
2 changed files with 3 additions and 2 deletions
|
@ -10,6 +10,7 @@ performance-for-range-copy,
|
|||
performance-inefficient-vector-operation,
|
||||
performance-move-const-arg,
|
||||
performance-no-automatic-move,
|
||||
performance-type-promotion-in-math-fn
|
||||
performance-unnecessary-copy-initialization,
|
||||
readability-const-return-type,
|
||||
readability-redundant-declaration,
|
||||
|
|
|
@ -68,8 +68,8 @@ void TrafficGraphWidget::paintEvent(QPaintEvent *)
|
|||
painter.drawLine(XMARGIN, YMARGIN + h, width() - XMARGIN, YMARGIN + h);
|
||||
|
||||
// decide what order of magnitude we are
|
||||
int base = floor(log10(fMax));
|
||||
float val = pow(10.0f, base);
|
||||
int base = std::floor(std::log10(fMax));
|
||||
float val = std::pow(10.0f, base);
|
||||
|
||||
const QString units = tr("kB/s");
|
||||
const float yMarginText = 2.0;
|
||||
|
|
Loading…
Add table
Reference in a new issue