Doc: define PY_SSIZE_T_CLEAN always (GH-12794)
(cherry picked from commit c88feceb449d6e85d7e17ec36559206094d10d81)
Co-authored-by: Inada Naoki <songofacandy@gmail.com>
diff --git a/Doc/faq/extending.rst b/Doc/faq/extending.rst
index 74e1af6..2ad2765 100644
--- a/Doc/faq/extending.rst
+++ b/Doc/faq/extending.rst
@@ -280,6 +280,7 @@
equal to ``E_EOF``, which means the input is incomplete. Here's a sample code
fragment, untested, inspired by code from Alex Farber::
+ #define PY_SSIZE_T_CLEAN
#include <Python.h>
#include <node.h>
#include <errcode.h>
@@ -318,6 +319,7 @@
#include <stdio.h>
#include <readline.h>
+ #define PY_SSIZE_T_CLEAN
#include <Python.h>
#include <object.h>
#include <compile.h>