Title: ctypes POINTER invalid incompatible type with None · Issue #12736 · python/typeshed · GitHub
Open Graph Title: ctypes POINTER invalid incompatible type with None · Issue #12736 · python/typeshed
X Title: ctypes POINTER invalid incompatible type with None · Issue #12736 · python/typeshed
Description: With type checkers (PyCharm's, MyPy) I get the error: mypy_test.py:6: error: Argument 1 to "POINTER" has incompatible type "None"; expected "type[Never]" [arg-type] Using this simple example: from ctypes import POINTER void = None POINTE...
Open Graph Description: With type checkers (PyCharm's, MyPy) I get the error: mypy_test.py:6: error: Argument 1 to "POINTER" has incompatible type "None"; expected "type[Never]" [arg-type] Using this simple example: from ...
X Description: With type checkers (PyCharm's, MyPy) I get the error: mypy_test.py:6: error: Argument 1 to "POINTER" has incompatible type "None"; expected "type[Never]" [arg-type...
Opengraph URL: https://github.com/python/typeshed/issues/12736
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"ctypes POINTER invalid incompatible type with None","articleBody":"With type checkers (PyCharm's, MyPy) I get the error:\r\n`mypy_test.py:6: error: Argument 1 to \"POINTER\" has incompatible type \"None\"; expected \"type[Never]\" [arg-type]`\r\n\r\nUsing this simple example:\r\n```\r\nfrom ctypes import POINTER\r\nvoid = None\r\nPOINTER(void)\r\n```\r\n`POINTER(None)` in ctypes is equivalent to `c_void_p` and is valid when ran. Minor issue but is technically a compatible type.","author":{"url":"https://github.com/caffeinepills","@type":"Person","name":"caffeinepills"},"datePublished":"2024-10-04T18:23:09Z","url":"https://github.com/python/typeshed/issues/12736"}
| 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:51107394-79ed-70b6-ef23-9ea8e4c13355 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B104:C5FC2:232F01E:2E8D548:6B00531F |
| html-safe-nonce | 455619a53c8f7e11e2142811ddea753c4f351cab669f44b10402d47d2f7a978a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCMTA0OkM1RkMyOjIzMkYwMUU6MkU4RDU0ODo2QjAwNTMxRiIsInZpc2l0b3JfaWQiOiI5MTQ5ODM4ODczMjE0NTMzNDMiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 4ceda4aa8ea8347cfd2fc59e92fea7f61d194108e03bd65ada52b5bb904796a9 |
| hovercard-subject-tag | issue:2567024778 |
| 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/typeshed/12736/issue_layout |
| twitter:image | https://opengraph.githubassets.com/877be3017638812fd0866defc0598f2e2192e720ba5e49506a0d72acef1b7254/python/typeshed/issues/12736 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/877be3017638812fd0866defc0598f2e2192e720ba5e49506a0d72acef1b7254/python/typeshed/issues/12736 |
| og:image:alt | With type checkers (PyCharm's, MyPy) I get the error: mypy_test.py:6: error: Argument 1 to "POINTER" has incompatible type "None"; expected "type[Never]" [arg-type] Using this simple example: from ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | caffeinepills |
| hostname | github.com |
| expected-hostname | github.com |
| None | f420f4996e6b1ff1ccd6d7683f8134f4b5f0f8a50124c210dbfe7490e5644abb |
| turbo-cache-control | no-preview |
| go-import | github.com/python/typeshed git https://github.com/python/typeshed.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 31696383 |
| octolytics-dimension-repository_nwo | python/typeshed |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 31696383 |
| octolytics-dimension-repository_network_root_nwo | python/typeshed |
| 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 | 26e00df917aba0f128135dc073ea0c5e33a70d40 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width