@@ -274,7 +274,7 @@ index 570a5581..feb1f95c 100644
274
274
}
275
275
276
276
diff --git a/third_party/pybind11/include/pybind11/pybind11.h b/third_party/pybind11/include/pybind11/pybind11.h
277
- index d46de579..2f015c6e 100644
277
+ index 818115cc..b4b3bf93 100644
278
278
--- a/third_party/pybind11/include/pybind11/pybind11.h
279
279
+++ b/third_party/pybind11/include/pybind11/pybind11.h
280
280
@@ -551,7 +551,7 @@ protected:
@@ -347,7 +347,7 @@ index 1293a0fd..dfb4385a 100644
347
347
+ torch._C._DisableFuncTorch():
348
348
return _str_intern(self, tensor_contents=tensor_contents)
349
349
diff --git a/torch/csrc/Module.cpp b/torch/csrc/Module.cpp
350
- index b85e94d2 ..0168b101 100644
350
+ index bbf99ce4 ..0168b101 100644
351
351
--- a/torch/csrc/Module.cpp
352
352
+++ b/torch/csrc/Module.cpp
353
353
@@ -341,46 +341,16 @@ PyObject* THPModule_addDocStr(PyObject* _unused, PyObject* args) {
@@ -356,13 +356,13 @@ index b85e94d2..0168b101 100644
356
356
357
357
- if (Py_TYPE(obj) == &PyCFunction_Type) {
358
358
- PyCFunctionObject* f = (PyCFunctionObject*)obj;
359
- - if (PyObject_GetDoc ((PyObject*)(f))) {
359
+ - if (GraalPyCFunction_GetDoc ((PyObject*)(f))) {
360
360
- return PyErr_Format(
361
361
- PyExc_RuntimeError,
362
362
- "function '%s' already has a docstring",
363
363
- _PyCFunction_GetMethodDef((PyObject*)(f))->ml_name);
364
364
- }
365
- - PyObject_SetDoc ((PyObject*)(f), doc_str);
365
+ - GraalPyCFunction_SetDoc ((PyObject*)(f), doc_str);
366
366
- } else if (strcmp(Py_TYPE(obj)->tp_name, "method_descriptor") == 0) {
367
367
- PyMethodDescrObject* m = (PyMethodDescrObject*)obj;
368
368
- if (m->d_method->ml_doc) {
0 commit comments