File tree Expand file tree Collapse file tree 1 file changed +13
-14
lines changed Expand file tree Collapse file tree 1 file changed +13
-14
lines changed Original file line number Diff line number Diff line change 1
1
use formality:: test_where_clause;
2
2
3
+ const MIRROR : & str = "[
4
+ crate core {
5
+ trait Mirror<> where [] {
6
+ type Assoc<> : [] where [];
7
+ }
8
+
9
+ impl<ty T> Mirror<> for T where [] {
10
+ type Assoc<> = T where [];
11
+ }
12
+ }
13
+ ]" ;
14
+
3
15
#[ test]
4
16
fn test_mirror_normalizes_u32_to_u32 ( ) {
5
- // Variant of test_foo_crate_cannot_assume_CoreStruct_does_not_impl_CoreTrait
6
- // where there is a negative impl, so it is accepted.
7
-
8
17
expect_test:: expect![ [ r#"
9
18
Ok(
10
19
{
@@ -36,17 +45,7 @@ fn test_mirror_normalizes_u32_to_u32() {
36
45
)
37
46
"# ] ]
38
47
. assert_debug_eq ( & test_where_clause (
39
- "[
40
- crate core {
41
- trait Mirror<> where [] {
42
- type Assoc<> : [] where [];
43
- }
44
-
45
- impl<ty T> Mirror<> for T where [] {
46
- type Assoc<> = T where [];
47
- }
48
- }
49
- ]" ,
48
+ MIRROR ,
50
49
"exists<ty T> {} => {<u32 as Mirror>::Assoc<> = T}" ,
51
50
) ) ;
52
51
}
You can’t perform that action at this time.
0 commit comments