8000 bpo-24766: doc= argument to subclasses of property not handled correctly by embray · Pull Request #2487 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

bpo-24766: doc= argument to subclasses of property not handled correctly #2487

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jun 10, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Prev Previous commit
Next Next commit
fix review comments
  • Loading branch information
embray committed Aug 4, 2020
commit 924a8a6dd4a90ce0c7d8734dd8b4cfbb8f2664e7
2 changes: 1 addition & 1 deletion Objects/descrobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -1713,7 +1713,7 @@ property_init_impl(propertyobject *self, PyObject *fget, PyObject *fset,
/* If this is a property subclass, put __doc__ in dict of the subclass
instance as well, otherwise it gets shadowed by __doc__ in the
class's dict. */
if (Py_IS_TYPE(self, &PyProperty_Type)) {
if (Py_IS_TYPE(self, &PyProperty_Type) && self->prop_doc != NULL) {
int err = _PyObject_SetAttrId((PyObject *)self, &PyId___doc__,
self->prop_doc);
if (err < 0) {
Expand Down
0