Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement the Buffer trait #908

Closed
wants to merge 5 commits into from

Implement Buffer for fs

7697e6c
Select commit
Loading
Failed to load commit list.
Closed

Implement the Buffer trait #908

Implement Buffer for fs
7697e6c
Select commit
Loading
Failed to load commit list.
This check has been archived and is scheduled for deletion. Learn more about checks retention
Cirrus CI / stable x86_64-unknown-freebsd-14 failed Oct 29, 2023 in 36s

Task Summary

Instruction test failed in 00:22

Details

⚠️ Not enough compute credits to prioritize tasks!

✅ 00:01 clone
✅ 00:10 setup
❌ 00:22 test

   |

error[E0277]: the trait bound `&mut Vec<{integer}>: Buffer<u8>` is not satisfied
  --> tests/net/v6.rs:38:17
   |
38 |     let nread = recv(&data_socket, &mut buffer, RecvFlags::empty()).unwrap();
   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Buffer<u8>` is not implemented for `&mut Vec<{integer}>`
   |
   = help: the trait `Buffer<T>` is implemented for `Vec<T>`

error[E0277]: the trait bound `&mut Vec<u8>: Buffer<u8>` is not satisfied
  --> tests/net/v6.rs:38:17
   |
38 |     let nread = recv(&data_socket, &mut buffer, RecvFlags::empty()).unwrap();
   |                 ^^^^ the trait `Buffer<u8>` is not implemented for `&mut Vec<u8>`
   |
   = help: the trait `Buffer<T>` is implemented for `Vec<T>`

error[E0277]: the trait bound `&mut Vec<{integer}>: Buffer<u8>` is not satisfied
  --> tests/net/v6.rs:62:36
   |
62 |     let nread = recv(&data_socket, &mut buffer, RecvFlags::empty()).unwrap();
   |                 ----               ^^^^^^^^^^^ the trait `Buffer<u8>` is not implemented for `&mut Vec<{integer}>`
   |                 |
   |                 required by a bound introduced by this call
   |
note: required by a bound in `recv`
  --> /tmp/cirrus-ci-build/src/net/send_recv/mod.rs:59:28
   |
59 | pub fn recv<Fd: AsFd, Buf: Buffer<u8>>(fd: Fd, buf: Buf, flags: RecvFlags) -> io::Result<Buf::Result> {
   |                            ^^^^^^^^^^ required by this bound in `recv`
help: consider removing the leading `&`-reference
   |
62 -     let nread = recv(&data_socket, &mut buffer, RecvFlags::empty()).unwrap();
62 +     let nread = recv(&data_socket, buffer, RecvFlags::empty()).unwrap();
   |

error[E0277]: the trait bound `&mut Vec<{integer}>: Buffer<u8>` is not satisfied
  --> tests/net/v6.rs:62:17
   |
62 |     let nread = recv(&data_socket, &mut buffer, RecvFlags::empty()).unwrap();
   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Buffer<u8>` is not implemented for `&mut Vec<{integer}>`
   |
   = help: the trait `Buffer<T>` is implemented for `Vec<T>`

error[E0277]: the trait bound `&mut Vec<u8>: Buffer<u8>` is not satisfied
  --> tests/net/v6.rs:62:17
   |
62 |     let nread = recv(&data_socket, &mut buffer, RecvFlags::empty()).unwrap();
   |                 ^^^^ the trait `Buffer<u8>` is not implemented for `&mut Vec<u8>`
   |
   = help: the trait `Buffer<T>` is implemented for `Vec<T>`

error: could not compile `rustix` (test "net") due to 72 previous errors

Exit status: 101