Skip to content

Commit a94b2ff

Browse files
haataeldruin
authored andcommitted
Fix compiler warnings
- field xxx is never read - associated funct xxx is never used
1 parent 2297008 commit a94b2ff

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/lib.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ fn _ensure_sync() {
199199
use crate::class_prelude::*;
200200

201201
struct DummyBus<'a> {
202-
a: &'a str,
202+
_a: &'a str,
203203
}
204204

205205
impl UsbBus for DummyBus<'_> {
@@ -239,12 +239,14 @@ fn _ensure_sync() {
239239
}
240240

241241
struct DummyClass<'a, B: UsbBus> {
242-
ep: crate::endpoint::EndpointIn<'a, B>,
242+
_ep: crate::endpoint::EndpointIn<'a, B>,
243243
}
244244

245245
impl<B: UsbBus> DummyClass<'_, B> {
246-
fn new(alloc: &UsbBusAllocator<B>) -> DummyClass<'_, B> {
247-
DummyClass { ep: alloc.bulk(64) }
246+
fn _new(alloc: &UsbBusAllocator<B>) -> DummyClass<'_, B> {
247+
DummyClass {
248+
_ep: alloc.bulk(64),
249+
}
248250
}
249251
}
250252

0 commit comments

Comments
 (0)