mirror of
https://github.com/italicsjenga/rp-hal-boards.git
synced 2024-12-23 20:51:31 +11:00
Fix comments on {read,write}_raw() functions
This commit is contained in:
parent
8d29464ee3
commit
d9b1b2b1ec
|
@ -247,7 +247,7 @@ impl<D: UARTDevice> UARTPeripheral<Enabled, D> {
|
|||
/// This function writes as long as it can. As soon that the FIFO is full, if :
|
||||
/// - 0 bytes were written, a WouldBlock Error is returned
|
||||
/// - some bytes were written, it is deemed to be a success
|
||||
/// Upon success, the number of written bytes is returned.
|
||||
/// Upon success, the remaining slice is returned.
|
||||
pub fn write_raw<'d>(&self, data: &'d [u8]) -> nb::Result<&'d [u8], Infallible> {
|
||||
let mut bytes_written = 0;
|
||||
|
||||
|
@ -274,7 +274,7 @@ impl<D: UARTDevice> UARTPeripheral<Enabled, D> {
|
|||
/// This function reads as long as it can. As soon that the FIFO is empty, if :
|
||||
/// - 0 bytes were read, a WouldBlock Error is returned
|
||||
/// - some bytes were read, it is deemed to be a success
|
||||
/// Upon success, the number of read bytes is returned.
|
||||
/// Upon success, the remaining slice is returned.
|
||||
pub fn read_raw<'b>(&self, buffer: &'b mut [u8]) -> nb::Result<&'b mut [u8], ReadError<'b>> {
|
||||
let mut bytes_read = 0;
|
||||
|
||||
|
|
Loading…
Reference in a new issue