usb: remove msos dead code
//!
//! <https://docs.microsoft.com/en-us/windows-hardware/drivers/usbcon/microsoft-os-2-0-descriptors-specification>
-#![allow(dead_code)]
-
use core::mem::size_of;
use core::ops::Range;
@@ -91,17 +89,6 @@ impl<'a> DescriptorSetBuilder<'a> {
self.used += size;
}
- pub fn subset(&mut self, build_subset: impl FnOnce(&mut DescriptorSetBuilder<'_>)) {
- self.used += {
- let mut subset = DescriptorSetBuilder {
- used: 0,
- buf: self.remaining(),
- };
- build_subset(&mut subset);
- subset.used
- };
- }
-
pub fn remaining(&mut self) -> &mut [u8] {
&mut self.buf[self.used..]
}
