File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ pub trait DelayNs {
16
16
fn delay_us ( & mut self , mut us : u32 ) {
17
17
const MAX_MICROS : u32 = u32:: MAX / NANOS_PER_MICRO ;
18
18
19
- // Avoid potential overflow if micro -> micro conversion is too large
19
+ // Avoid potential overflow if micro -> nano conversion is too large
20
20
while us > MAX_MICROS {
21
21
us -= MAX_MICROS ;
22
22
self . delay_ns ( MAX_MICROS * NANOS_PER_MICRO ) ;
@@ -31,7 +31,7 @@ pub trait DelayNs {
31
31
fn delay_ms ( & mut self , mut ms : u32 ) {
32
32
const MAX_MILLIS : u32 = u32:: MAX / NANOS_PER_MILLI ;
33
33
34
- // Avoid potential overflow if milli -> micro conversion is too large
34
+ // Avoid potential overflow if milli -> nano conversion is too large
35
35
while ms > MAX_MILLIS {
36
36
ms -= MAX_MILLIS ;
37
37
self . delay_ns ( MAX_MILLIS * NANOS_PER_MILLI ) ;
You can’t perform that action at this time.
0 commit comments