From b3b630724794e71ebb4374b4b2eb6bda9c2fed0b Mon Sep 17 00:00:00 2001 From: Shreyan Avigyan Date: Sat, 10 Apr 2021 16:22:13 +0530 Subject: [PATCH 1/2] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type. --- Doc/extending/extending.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/extending/extending.rst b/Doc/extending/extending.rst index 25dc2934d29ef6f..bc85a05ff2f8503 100644 --- a/Doc/extending/extending.rst +++ b/Doc/extending/extending.rst @@ -410,7 +410,7 @@ optionally followed by an import of the module:: /* Optionally import the module; alternatively, import can be deferred until the embedded script imports it. */ - pmodule = PyImport_ImportModule("spam"); + PyObject *pmodule = PyImport_ImportModule("spam"); if (!pmodule) { PyErr_Print(); fprintf(stderr, "Error: could not import module 'spam'\n"); From c0a56b6399fd22c5161f58e9f7886ec1229dae85 Mon Sep 17 00:00:00 2001 From: "blurb-it[bot]" <43283697+blurb-it[bot]@users.noreply.github.com> Date: Sat, 10 Apr 2021 10:57:34 +0000 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=93=9C=F0=9F=A4=96=20Added=20by=20blu?= =?UTF-8?q?rb=5Fit.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../next/Documentation/2021-04-10-10-57-33.bpo-43739.L4HjiX.rst | 1 + 1 file changed, 1 insertion(+) create mode 100644 Misc/NEWS.d/next/Documentation/2021-04-10-10-57-33.bpo-43739.L4HjiX.rst diff --git a/Misc/NEWS.d/next/Documentation/2021-04-10-10-57-33.bpo-43739.L4HjiX.rst b/Misc/NEWS.d/next/Documentation/2021-04-10-10-57-33.bpo-43739.L4HjiX.rst new file mode 100644 index 000000000000000..9f8d3625e79618d --- /dev/null +++ b/Misc/NEWS.d/next/Documentation/2021-04-10-10-57-33.bpo-43739.L4HjiX.rst @@ -0,0 +1 @@ +Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type. \ No newline at end of file