Title: Disallow List[int] etc. as expressions · Issue #556 · python/mypy · GitHub
Open Graph Title: Disallow List[int] etc. as expressions · Issue #556 · python/mypy
X Title: Disallow List[int] etc. as expressions · Issue #556 · python/mypy
Description: The current PEP 484 draft does not allow writing code like this: x = List[int]() Instead, the recommended way is using type annotations: x = [] # type: List[int] # or y = Undefined(List[int]) y = [] See also: python/typing#9
Open Graph Description: The current PEP 484 draft does not allow writing code like this: x = List[int]() Instead, the recommended way is using type annotations: x = [] # type: List[int] # or y = Undefined(List[int]) y = [...
X Description: The current PEP 484 draft does not allow writing code like this: x = List[int]() Instead, the recommended way is using type annotations: x = [] # type: List[int] # or y = Undefined(List[int]) y = [...
Opengraph URL: https://github.com/python/mypy/issues/556
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Disallow List[int] etc. as expressions","articleBody":"The current PEP 484 draft does not allow writing code like this:\n\n```\nx = List[int]()\n```\n\nInstead, the recommended way is using type annotations:\n\n```\nx = [] # type: List[int]\n# or\ny = Undefined(List[int])\ny = []\n```\n\nSee also: https://github.com/ambv/typehinting/issues/9\n","author":{"url":"https://github.com/JukkaL","@type":"Person","name":"JukkaL"},"datePublished":"2015-01-17T20:18:49Z","url":"https://github.com/python/mypy/issues/556"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:c06d8e2a-b685-eae1-9969-dc6a7c59f002 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B3DA:26B9F0:24F1B0:338441:6B006907 |
| html-safe-nonce | 285e0ae9aa689ae8adc1c7414ce0b61993d72693f63bc7b41b9b2e514b60bb74 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCM0RBOjI2QjlGMDoyNEYxQjA6MzM4NDQxOjZCMDA2OTA3IiwidmlzaXRvcl9pZCI6IjE4MTk2MTY1NjIzNjE5NTI1MTkiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | db00d01a1d18c61af918a86dd0cb7247d216ac7c6aa0d589c51cf9d0a4399ff6 |
| hovercard-subject-tag | issue:54673741 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/mypy/556/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c2872406337c1366ea19029d181f69a5a0c748e3b1445c6a2db7c809f2bd4b55/python/mypy/issues/556 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c2872406337c1366ea19029d181f69a5a0c748e3b1445c6a2db7c809f2bd4b55/python/mypy/issues/556 |
| og:image:alt | The current PEP 484 draft does not allow writing code like this: x = List[int]() Instead, the recommended way is using type annotations: x = [] # type: List[int] # or y = Undefined(List[int]) y = [... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | JukkaL |
| hostname | github.com |
| expected-hostname | github.com |
| None | 6527e91c60c0b29d16606ff32ac5df8ecdc37a2a62205ea057a14d7762c870fa |
| turbo-cache-control | no-preview |
| go-import | github.com/python/mypy git https://github.com/python/mypy.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 7053637 |
| octolytics-dimension-repository_nwo | python/mypy |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 7053637 |
| octolytics-dimension-repository_network_root_nwo | python/mypy |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 46f1cd2ae3cd8ae1a81019b5d619742e76f13bbd |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width