stm32: add missing + 'a
bounds on trait GATs
This commit is contained in:
parent
250f1cd0a5
commit
9bd34429f3
5 changed files with 9 additions and 9 deletions
|
@ -159,8 +159,8 @@ pac::dma_channels! {
|
|||
impl crate::dma::sealed::Channel for crate::peripherals::$channel_peri {}
|
||||
impl Channel for crate::peripherals::$channel_peri
|
||||
{
|
||||
type ReadFuture<'a> = impl Future<Output = ()>;
|
||||
type WriteFuture<'a> = impl Future<Output = ()>;
|
||||
type ReadFuture<'a> = impl Future<Output = ()> + 'a;
|
||||
type WriteFuture<'a> = impl Future<Output = ()> + 'a;
|
||||
|
||||
fn read<'a>(
|
||||
&'a mut self,
|
||||
|
|
|
@ -165,8 +165,8 @@ pac::dma_channels! {
|
|||
impl crate::dma::sealed::Channel for crate::peripherals::$channel_peri {}
|
||||
impl Channel for crate::peripherals::$channel_peri
|
||||
{
|
||||
type ReadFuture<'a> = impl Future<Output = ()>;
|
||||
type WriteFuture<'a> = impl Future<Output = ()>;
|
||||
type ReadFuture<'a> = impl Future<Output = ()> + 'a;
|
||||
type WriteFuture<'a> = impl Future<Output = ()> + 'a;
|
||||
|
||||
fn read<'a>(
|
||||
&'a mut self,
|
||||
|
|
|
@ -84,7 +84,7 @@ impl<T: Instance> CryptoRng for Random<T> {}
|
|||
impl<T: Instance> traits::rng::Rng for Random<T> {
|
||||
type Error = Error;
|
||||
#[rustfmt::skip]
|
||||
type RngFuture<'a> where Self: 'a = impl Future<Output=Result<(), Self::Error>>;
|
||||
type RngFuture<'a> where Self: 'a = impl Future<Output=Result<(), Self::Error>> + 'a;
|
||||
|
||||
fn fill_bytes<'a>(&'a mut self, dest: &'a mut [u8]) -> Self::RngFuture<'a> {
|
||||
unsafe {
|
||||
|
|
|
@ -153,7 +153,7 @@ impl<'d, T: Instance, RxDma> embedded_hal::blocking::serial::Write<u8>
|
|||
impl<'d, T: Instance, TxDma, RxDma> embassy_traits::uart::Write for Uart<'d, T, TxDma, RxDma>
|
||||
where TxDma: crate::usart::TxDma<T>
|
||||
{
|
||||
type WriteFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>>;
|
||||
type WriteFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>> + 'a;
|
||||
|
||||
fn write<'a>(&'a mut self, buf: &'a [u8]) -> Self::WriteFuture<'a> {
|
||||
self.write_dma(buf).map_err(|_| embassy_traits::uart::Error::Other)
|
||||
|
@ -165,7 +165,7 @@ impl<'d, T: Instance, TxDma, RxDma> embassy_traits::uart::Write for Uart<'d, T,
|
|||
impl<'d, T: Instance, TxDma, RxDma> embassy_traits::uart::Read for Uart<'d, T, TxDma, RxDma>
|
||||
where RxDma: crate::usart::RxDma<T>
|
||||
{
|
||||
type ReadFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>>;
|
||||
type ReadFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>> + 'a;
|
||||
|
||||
fn read<'a>(&'a mut self, buf: &'a mut [u8]) -> Self::ReadFuture<'a> {
|
||||
self.read_dma(buf).map_err(|_| embassy_traits::uart::Error::Other)
|
||||
|
|
|
@ -157,7 +157,7 @@ impl<'d, T: Instance, RxDma> embedded_hal::blocking::serial::Write<u8>
|
|||
impl<'d, T: Instance, TxDma, RxDma> embassy_traits::uart::Write for Uart<'d, T, TxDma, RxDma>
|
||||
where TxDma: crate::usart::TxDma<T>
|
||||
{
|
||||
type WriteFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>>;
|
||||
type WriteFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>> + 'a;
|
||||
|
||||
fn write<'a>(&'a mut self, buf: &'a [u8]) -> Self::WriteFuture<'a> {
|
||||
self.write_dma(buf).map_err(|_| embassy_traits::uart::Error::Other)
|
||||
|
@ -169,7 +169,7 @@ impl<'d, T: Instance, TxDma, RxDma> embassy_traits::uart::Write for Uart<'d, T,
|
|||
impl<'d, T: Instance, TxDma, RxDma> embassy_traits::uart::Read for Uart<'d, T, TxDma, RxDma>
|
||||
where RxDma: crate::usart::RxDma<T>
|
||||
{
|
||||
type ReadFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>>;
|
||||
type ReadFuture<'a> where Self: 'a = impl Future<Output = Result<(), embassy_traits::uart::Error>> + 'a;
|
||||
|
||||
fn read<'a>(&'a mut self, buf: &'a mut [u8]) -> Self::ReadFuture<'a> {
|
||||
self.read_dma(buf).map_err(|_| embassy_traits::uart::Error::Other)
|
||||
|
|
Loading…
Reference in a new issue