gh-132983: Remove pyzstd in identifiers (#133535)

This commit is contained in:
Rogdham 2025-05-08 02:47:42 +02:00 committed by GitHub
parent 9fcebb3611
commit 2cc6de77bd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 14 additions and 27 deletions

View file

@ -25,9 +25,9 @@ class _zstd.ZstdCompressor "ZstdCompressor *" "clinic_state()->ZstdCompressor_ty
#define ZstdCompressor_CAST(op) ((ZstdCompressor *)op)
int
_PyZstd_set_c_parameters(ZstdCompressor *self, PyObject *level_or_options,
const char *arg_name, const char* arg_type)
static int
_zstd_set_c_parameters(ZstdCompressor *self, PyObject *level_or_options,
const char *arg_name, const char* arg_type)
{
size_t zstd_ret;
_zstd_state* const mod_state = PyType_GetModuleState(Py_TYPE(self));
@ -197,8 +197,8 @@ success:
return cdict;
}
int
_PyZstd_load_c_dict(ZstdCompressor *self, PyObject *dict) {
static int
_zstd_load_c_dict(ZstdCompressor *self, PyObject *dict) {
size_t zstd_ret;
_zstd_state* const mod_state = PyType_GetModuleState(Py_TYPE(self));
@ -385,20 +385,20 @@ _zstd_ZstdCompressor___init___impl(ZstdCompressor *self, PyObject *level,
/* Set compressLevel/options to compression context */
if (level != Py_None) {
if (_PyZstd_set_c_parameters(self, level, "level", "int") < 0) {
if (_zstd_set_c_parameters(self, level, "level", "int") < 0) {
return -1;
}
}
if (options != Py_None) {
if (_PyZstd_set_c_parameters(self, options, "options", "dict") < 0) {
if (_zstd_set_c_parameters(self, options, "options", "dict") < 0) {
return -1;
}
}
/* Load dictionary to compression context */
if (zstd_dict != Py_None) {
if (_PyZstd_load_c_dict(self, zstd_dict) < 0) {
if (_zstd_load_c_dict(self, zstd_dict) < 0) {
return -1;
}