|
1 | | -Error -------------------------------------------------------------------------------- bad_interaction_with_evalt.js:4:5 |
| 1 | +Error -------------------------------------------------------------------------------- bad_interaction_with_evalt.js:4:1 |
2 | 2 |
|
3 | | -Cannot call `bad.get` because: [incompatible-type] |
4 | | - - Either cannot access `Obj2` [1] with computed property using string [2]. |
5 | | - - Or function type [3] requires another argument from call of method `get` [4]. |
| 3 | +Cannot cast `bad.get()` to `Obj2` because null [1] is incompatible with `Obj2` [2]. [incompatible-type] |
6 | 4 |
|
7 | | - bad_interaction_with_evalt.js:4:5 |
8 | | - 4| bad.get() as Obj2; // error: TODO should not error here, since annotation error should be non-speculative |
9 | | - ^^^ |
10 | | - |
11 | | -References: |
12 | | - exported_bad_evalt.js:8:21 |
13 | | - 8| export type Bad = C<Obj2[string]>; |
14 | | - ^^^^ [1] |
15 | | - exported_bad_evalt.js:8:26 |
16 | | - 8| export type Bad = C<Obj2[string]>; |
17 | | - ^^^^^^ [2] |
18 | | - exported_bad_evalt.js:3:3 |
19 | | - 3| get(v: T): T; |
20 | | - ^^^^^^^^^^^^ [3] |
21 | 5 | bad_interaction_with_evalt.js:4:1 |
22 | | - 4| bad.get() as Obj2; // error: TODO should not error here, since annotation error should be non-speculative |
23 | | - ^^^^^^^^^ [4] |
24 | | - |
25 | | - |
26 | | -Error -------------------------------------------------------------------------------- bad_interaction_with_evalt.js:5:5 |
27 | | - |
28 | | -Cannot call `bad.get` because: [incompatible-type] |
29 | | - - Either number [1] is incompatible with empty [2]. |
30 | | - - Or no arguments are expected by function type [3]. |
31 | | - |
32 | | - bad_interaction_with_evalt.js:5:5 |
33 | | - 5| bad.get(1) as Obj2; // error: TODO spurious incompatible with empty |
34 | | - ^^^ |
| 6 | + 4| bad.get() as Obj2; // only subtyping error |
| 7 | + ^^^^^^^^^ |
35 | 8 |
|
36 | 9 | References: |
37 | | - bad_interaction_with_evalt.js:5:9 |
38 | | - 5| bad.get(1) as Obj2; // error: TODO spurious incompatible with empty |
39 | | - ^ [1] |
40 | | - exported_bad_evalt.js:8:21 |
41 | | - 8| export type Bad = C<Obj2[string]>; |
42 | | - ^^^^^^^^^^^^ [2] |
43 | | - exported_bad_evalt.js:2:3 |
| 10 | + exported_bad_evalt.js:2:14 |
44 | 11 | 2| get(): T | null; |
45 | | - ^^^^^^^^^^^^^^^ [3] |
| 12 | + ^^^^ [1] |
| 13 | + bad_interaction_with_evalt.js:4:14 |
| 14 | + 4| bad.get() as Obj2; // only subtyping error |
| 15 | + ^^^^ [2] |
46 | 16 |
|
47 | 17 |
|
48 | 18 | Error ------------------------------------------------------------------------------------- errors_intersection.js:13:13 |
@@ -3942,7 +3912,7 @@ References: |
3942 | 3912 |
|
3943 | 3913 |
|
3944 | 3914 |
|
3945 | | -Found 186 errors |
| 3915 | +Found 185 errors |
3946 | 3916 |
|
3947 | 3917 | Only showing the most relevant union/intersection branches. |
3948 | 3918 | To see all branches, re-run Flow with --show-all-branches |
0 commit comments