Replaced outdated macros _PyUnicode_AsString and _PyUnicode_AsStringAndSize
with PyUnicode_AsUTF8 and PyUnicode_AsUTF8AndSize.
diff --git a/Modules/_datetimemodule.c b/Modules/_datetimemodule.c
index 5ddf650..d0ddcc2 100644
--- a/Modules/_datetimemodule.c
+++ b/Modules/_datetimemodule.c
@@ -1219,7 +1219,7 @@
     assert(object && format && timetuple);
     assert(PyUnicode_Check(format));
     /* Convert the input format to a C string and size */
-    pin = _PyUnicode_AsStringAndSize(format, &flen);
+    pin = PyUnicode_AsUTF8AndSize(format, &flen);
     if (!pin)
         return NULL;
 
@@ -1287,7 +1287,7 @@
             }
             assert(Zreplacement != NULL);
             assert(PyUnicode_Check(Zreplacement));
-            ptoappend = _PyUnicode_AsStringAndSize(Zreplacement,
+            ptoappend = PyUnicode_AsUTF8AndSize(Zreplacement,
                                                   &ntoappend);
             if (ptoappend == NULL)
                 goto Done;