Skip to content

Commit b84de57

Browse files
committed
Implement Default for SysTimer
1 parent 969d94c commit b84de57

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
1616
### Added
1717

1818
- `CountDown` implementation for `SysTimer`.
19+
- `Default` implementation for `SysTimer`.
1920

2021
### Changed
2122

src/timer.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ impl SysTimer {
2929
}
3030
}
3131

32+
impl Default for SysTimer {
33+
fn default() -> SysTimer {
34+
SysTimer::new()
35+
}
36+
}
37+
3238
impl CountDown for SysTimer {
3339
type Error = Infallible;
3440
type Time = Duration;

0 commit comments

Comments
 (0)