File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -524,6 +524,9 @@ impl<I: Interner> Zip<I> for FnSubst<I> {
524
524
b : & Self ,
525
525
) -> Fallible < ( ) > {
526
526
let interner = zipper. interner ( ) ;
527
+ if a. 0 . len ( interner) != b. 0 . len ( interner) {
528
+ return Err ( NoSolution ) ;
529
+ }
527
530
// Parameters
528
531
for ( a, b) in a. 0 . as_slice ( interner) [ ..a. 0 . len ( interner) - 1 ]
529
532
. iter ( )
Original file line number Diff line number Diff line change @@ -149,6 +149,13 @@ fn forall_equality() {
149
149
expect![ [ "Unique" ] ]
150
150
}
151
151
152
+ goal {
153
+ // Function pointers with different parameters should not be equal.
154
+ fn ( u32 ) : Eq <fn ( u32 , u32 ) >
155
+ } yields {
156
+ expect![ [ "No possible solution" ] ]
157
+ }
158
+
152
159
goal {
153
160
// Variadic function pointers should not be equal to non-variadic fn pointers.
154
161
fn ( u8 , ...) : Eq <fn ( u8 ) >
You can’t perform that action at this time.
0 commit comments