Commit 62d43b8
committed
Be stricter about access to generic vars from class
This behaviour was intentionally chosen in #6418
I agree with Ivan's comment there that it's similar to how mypy allows
instantiation of `type[Abstract]` -- but that's a thing that I want to
explore disallowing.
Let's see primer1 parent 1f200dd commit 62d43b8
File tree
3 files changed
+23
-15
lines changed- mypy
- test-data/unit
3 files changed
+23
-15
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1087 | 1087 | | |
1088 | 1088 | | |
1089 | 1089 | | |
1090 | | - | |
1091 | | - | |
1092 | | - | |
1093 | | - | |
1094 | | - | |
1095 | | - | |
1096 | | - | |
| 1090 | + | |
| 1091 | + | |
| 1092 | + | |
| 1093 | + | |
| 1094 | + | |
1097 | 1095 | | |
1098 | 1096 | | |
1099 | 1097 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
282 | 282 | | |
283 | 283 | | |
284 | 284 | | |
285 | | - | |
| 285 | + | |
286 | 286 | | |
287 | 287 | | |
288 | 288 | | |
289 | 289 | | |
290 | 290 | | |
291 | | - | |
| 291 | + | |
292 | 292 | | |
293 | | - | |
294 | | - | |
295 | | - | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
296 | 306 | | |
297 | 307 | | |
298 | 308 | | |
| |||
311 | 321 | | |
312 | 322 | | |
313 | 323 | | |
314 | | - | |
| 324 | + | |
315 | 325 | | |
316 | 326 | | |
317 | 327 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2225 | 2225 | | |
2226 | 2226 | | |
2227 | 2227 | | |
2228 | | - | |
| 2228 | + | |
2229 | 2229 | | |
2230 | 2230 | | |
2231 | 2231 | | |
| |||
2288 | 2288 | | |
2289 | 2289 | | |
2290 | 2290 | | |
2291 | | - | |
| 2291 | + | |
2292 | 2292 | | |
2293 | 2293 | | |
2294 | 2294 | | |
| |||
0 commit comments