diff options
author | Andrew Kaster <akaster@serenityos.org> | 2023-01-01 22:50:49 -0700 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2023-01-07 14:51:04 +0100 |
commit | a492e2018de1271659732ef7634ee2b9eb3ba719 (patch) | |
tree | a5f9ea815e20bafe7ee7b028aab6421c2c85b8ec /Userland/Shell | |
parent | 48bf0b1408880422f1dea7c3f1330f18560f361b (diff) | |
download | serenity-a492e2018de1271659732ef7634ee2b9eb3ba719.zip |
Userland: Silence warnings from ElapsedTimer::elapsed() type change
We changed elapsed() to return i64 instead of int as that's what
AK::Time::to_milliseconds() returns, causing a bunch of implicit lossy
conversions in callers. Clean those up with a mix of type changes and
casts.
Diffstat (limited to 'Userland/Shell')
-rw-r--r-- | Userland/Shell/Builtin.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Shell/Builtin.cpp b/Userland/Shell/Builtin.cpp index e0315d8ee9..770da10c41 100644 --- a/Userland/Shell/Builtin.cpp +++ b/Userland/Shell/Builtin.cpp @@ -1007,7 +1007,7 @@ int Shell::builtin_time(int argc, char const** argv) block_on_job(job); exit_code = job.exit_code(); } - iteration_times.add(timer.elapsed()); + iteration_times.add(static_cast<float>(timer.elapsed())); } if (number_of_iterations == 1) { |