Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
gh-93911:LOAD_ATTR_PROPERTY#93912
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Changes fromall commits
c9966d1e66782bc7bde646a03dadc78831dd03cc6136af644c20af473d5d5fd7f45ec1a6c4ab3626bfa14786bac9f32d03File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| #ifndefPy_INTERNAL_DESCROBJECT_H | ||
Member There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. Maybe "pycore_property.h" as it is just the property struct. MemberAuthor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. I'm leaving it generic from now (and naming it after the file it came from) so that I can re-use it again in the future when I add more specialisations. (E.g. classmethod is also from the same file) Member There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. Do properties and classmethods really belong in the same file? Sure, they are both descriptors, but so are Python functions. Member There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. If you don't want to change it for this PR, that's fine too. | ||
| #definePy_INTERNAL_DESCROBJECT_H | ||
| #ifdef__cplusplus | ||
| extern"C" { | ||
| #endif | ||
| #ifndefPy_BUILD_CORE | ||
| # error "this header requires Py_BUILD_CORE define" | ||
| #endif | ||
| typedefstruct { | ||
| PyObject_HEAD | ||
| PyObject*prop_get; | ||
| PyObject*prop_set; | ||
| PyObject*prop_del; | ||
| PyObject*prop_doc; | ||
| PyObject*prop_name; | ||
| intgetter_doc; | ||
| }propertyobject; | ||
| typedefpropertyobject_PyPropertyObject; | ||
| #ifdef__cplusplus | ||
| } | ||
| #endif | ||
| #endif/* !Py_INTERNAL_DESCROBJECT_H */ | ||
Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.
Uh oh!
There was an error while loading.Please reload this page.
Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.
Uh oh!
There was an error while loading.Please reload this page.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| Specialize ``LOAD_ATTR`` for ``property()`` attributes. |
Uh oh!
There was an error while loading.Please reload this page.