]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/array-impls/alloc-traits-impls-length-32.rs
Rollup merge of #63055 - Mark-Simulacrum:save-analysis-clean-2, r=Xanewok
[rust.git] / src / test / ui / const-generics / array-impls / alloc-traits-impls-length-32.rs
1 // check-pass
2
3 pub fn yes_vec_partial_eq_array<A, B>() -> impl PartialEq<[B; 32]>
4 where
5     A: PartialEq<B>,
6 {
7     Vec::<A>::new()
8 }
9
10 pub fn yes_vec_partial_eq_ref_array<'a, A, B>() -> impl PartialEq<&'a [B; 32]>
11 where
12     A: PartialEq<B>,
13 {
14     Vec::<A>::new()
15 }
16
17 use std::collections::VecDeque;
18
19 pub fn yes_vecdeque_partial_eq_array<A, B>() -> impl PartialEq<[B; 32]>
20 where
21     A: PartialEq<B>,
22 {
23     VecDeque::<A>::new()
24 }
25
26 pub fn yes_vecdeque_partial_eq_ref_array<'a, A, B>() -> impl PartialEq<&'a [B; 32]>
27 where
28     A: PartialEq<B>,
29 {
30     VecDeque::<A>::new()
31 }
32
33 pub fn yes_vecdeque_partial_eq_ref_mut_array<'a, A, B>() -> impl PartialEq<&'a mut [B; 32]>
34 where
35     A: PartialEq<B>,
36 {
37     VecDeque::<A>::new()
38 }
39
40 fn main() {}