Deepfreeze essential parts of the encodings module. ### Description

This is a split off from #3582.

Deepfreeze essential parts of encodings module (encodings.\__init__, encodings.utf_8, and encodings.aliases), which is required during the Python bootstrap.

From e6e9ca182ef403b4fca9033a48969f33e7a5c10d Mon Sep 17 00:00:00 2001
From: Hood Chatham <roberthoodchatham@gmail.com>
Date: Sat, 27 Aug 2022 21:58:46 -0700
Subject: [PATCH] Add consts to PyUFuncGenericFunction declarations

---
 src/_ufuncs.c | 52 +++++++++++++++++++++++++--------------------------
 1 file changed, 26 insertions(+), 26 deletions(-)

diff --git a/src/_ufuncs.c b/src/_ufuncs.c
index 0db4c44..c69ced8 100644
--- a/src/_ufuncs.c
+++ b/src/_ufuncs.c
@@ -26,8 +26,8 @@ This is python 3-only (for simplicity) to begin with.
 
 
 /* 1 in, 1 out */
-static void loop1d_d_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_d_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -59,8 +59,8 @@ static char types_d_d[] = {
 };
 
 /* 2 in, 1 out */
-static void loop1d_dd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -95,8 +95,8 @@ static char types_dd_d[] = {
 };
 
 /* 3 in, 1 out */
-static void loop1d_ddd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -134,8 +134,8 @@ static char types_ddd_d[] = {
 };
 
 /* 4 in, 1 out */
-static void loop1d_dddd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dddd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -176,8 +176,8 @@ static char types_dddd_d[] = {
 };
 
 /* 5 in, 1 out */
-static void loop1d_ddddd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddddd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -221,8 +221,8 @@ static char types_ddddd_d[] = {
 };
 
 /* 2 in, 2 out */
-static void loop1d_dd_dd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dd_dd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -261,8 +261,8 @@ static char types_dd_dd[] = {
 };
 
 /* 3 in, 2 out */
-static void loop1d_ddd_dd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_dd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -304,8 +304,8 @@ static char types_ddd_dd[] = {
 };
 
 /* 3 in, 3 out */
-static void loop1d_ddd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -351,8 +351,8 @@ static char types_ddd_ddd[] = {
 };
 
 /* 6 in, 2 out */
-static void loop1d_dddddd_dd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dddddd_dd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -403,8 +403,8 @@ static char types_dddddd_dd[] = {
 };
 
 /* 2 in, 3 out */
-static void loop1d_dd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -447,8 +447,8 @@ static char types_dd_ddd[] = {
 };
 
 /* 4 in, 3 out */
-static void loop1d_dddd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dddd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -497,8 +497,8 @@ static char types_dddd_ddd[] = {
 };
 
 /* 5 in, 3 out */
-static void loop1d_ddddd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddddd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -550,8 +550,8 @@ static char types_ddddd_ddd[] = {
 };
 
 /* 3 in, 5 out */
-static void loop1d_ddd_ddddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_ddddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
-- 
2.25.1


From e6e9ca182ef403b4fca9033a48969f33e7a5c10d Mon Sep 17 00:00:00 2001
From: Hood Chatham <roberthoodchatham@gmail.com>
Date: Sat, 27 Aug 2022 21:58:46 -0700
Subject: [PATCH] Add consts to PyUFuncGenericFunction declarations

---
 src/_ufuncs.c | 52 +++++++++++++++++++++++++--------------------------
 1 file changed, 26 insertions(+), 26 deletions(-)

diff --git a/src/_ufuncs.c b/src/_ufuncs.c
index 0db4c44..c69ced8 100644
--- a/src/_ufuncs.c
+++ b/src/_ufuncs.c
@@ -26,8 +26,8 @@ This is python 3-only (for simplicity) to begin with.
 
 
 /* 1 in, 1 out */
-static void loop1d_d_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_d_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -59,8 +59,8 @@ static char types_d_d[] = {
 };
 
 /* 2 in, 1 out */
-static void loop1d_dd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -95,8 +95,8 @@ static char types_dd_d[] = {
 };
 
 /* 3 in, 1 out */
-static void loop1d_ddd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -134,8 +134,8 @@ static char types_ddd_d[] = {
 };
 
 /* 4 in, 1 out */
-static void loop1d_dddd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dddd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -176,8 +176,8 @@ static char types_dddd_d[] = {
 };
 
 /* 5 in, 1 out */
-static void loop1d_ddddd_d(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddddd_d(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -221,8 +221,8 @@ static char types_ddddd_d[] = {
 };
 
 /* 2 in, 2 out */
-static void loop1d_dd_dd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dd_dd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -261,8 +261,8 @@ static char types_dd_dd[] = {
 };
 
 /* 3 in, 2 out */
-static void loop1d_ddd_dd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_dd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -304,8 +304,8 @@ static char types_ddd_dd[] = {
 };
 
 /* 3 in, 3 out */
-static void loop1d_ddd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -351,8 +351,8 @@ static char types_ddd_ddd[] = {
 };
 
 /* 6 in, 2 out */
-static void loop1d_dddddd_dd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dddddd_dd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -403,8 +403,8 @@ static char types_dddddd_dd[] = {
 };
 
 /* 2 in, 3 out */
-static void loop1d_dd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -447,8 +447,8 @@ static char types_dd_ddd[] = {
 };
 
 /* 4 in, 3 out */
-static void loop1d_dddd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_dddd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -497,8 +497,8 @@ static char types_dddd_ddd[] = {
 };
 
 /* 5 in, 3 out */
-static void loop1d_ddddd_ddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddddd_ddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
@@ -550,8 +550,8 @@ static char types_ddddd_ddd[] = {
 };
 
 /* 3 in, 5 out */
-static void loop1d_ddd_ddddd(char **args, npy_intp *dimensions,
-                          npy_intp* steps, void* data)
+static void loop1d_ddd_ddddd(char **args, const npy_intp *dimensions,
+                          const npy_intp* steps, void* data)
 {
     npy_intp i;
     npy_intp n = dimensions[0];
-- 
2.25.1

