chronotope / chrono

Date and time library for Rust
Other
3.3k stars 523 forks source link

`TimeZone` trait: take `NaiveDateTime` by value #1522

Closed pitdicker closed 6 months ago

pitdicker commented 6 months ago

Adjust TimeZone::{offset_from_local_datetime, offset_from_utc_datetime, from_local_datetime, from_utc_datetime} to take their NaiveDateTime argument by value. Taking a small Copy value by reference was useless friction.

codecov[bot] commented 6 months ago

Codecov Report

Attention: Patch coverage is 92.36641% with 10 lines in your changes are missing coverage. Please review.

Project coverage is 94.01%. Comparing base (d286f93) to head (d035716).

Files Patch % Lines
src/datetime/tests.rs 87.27% 7 Missing :warning:
src/datetime/mod.rs 78.57% 3 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## 0.5.x #1522 +/- ## ========================================== - Coverage 94.01% 94.01% -0.01% ========================================== Files 37 37 Lines 16830 16824 -6 ========================================== - Hits 15823 15817 -6 Misses 1007 1007 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.