Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-132983: Clean-ups for_zstd#133670

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
AA-Turner merged 16 commits intopython:mainfromAA-Turner:zstd-clean
May 9, 2025
Merged
Changes from1 commit
Commits
Show all changes
16 commits
Select commitHold shift + click to select a range
0c3c667
zstd: replace star import with explicit names
AA-TurnerMay 8, 2025
e02f66c
zstd: factor common parts of set_zstd_error()
AA-TurnerMay 8, 2025
686ae61
zstd: Remove ZSTD_versionString from error messages
AA-TurnerMay 8, 2025
7ea1ac1
zstd: Simplify version_info setup
AA-TurnerMay 8, 2025
9774338
zstd: Replace _compressionLevel_values with ZSTD_CLEVEL_DEFAULT
AA-TurnerMay 8, 2025
d1dea98
zstd: Remove _ZSTD_CStreamSizes, replace _ZSTD_DStreamSizes with ZSTD…
AA-TurnerMay 8, 2025
ac1e39c
zstd: Remove _ZSTD_CONFIG
AA-TurnerMay 8, 2025
1a54bf3
zstd: Replace add_parameters and ADD_INT_PREFIX_MACRO with PyModule_A…
AA-TurnerMay 8, 2025
9cb7a3d
Merge branch 'main' into zstd-clean
AA-TurnerMay 8, 2025
663e666
Revert "zstd: factor common parts of set_zstd_error()"
AA-TurnerMay 8, 2025
dd1380d
Use PyModule_Add
AA-TurnerMay 9, 2025
fcd6561
Check failure cases for int macros
AA-TurnerMay 9, 2025
06a4723
Remove ERR_SET_PLEDGED_INPUT_SIZE
AA-TurnerMay 9, 2025
ef2634d
Use PyLong_FromSize_t
AA-TurnerMay 9, 2025
ff28bf2
Use runtime version
AA-TurnerMay 9, 2025
3d3dbf7
Calculate zstd_version_info in Python
AA-TurnerMay 9, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
Revert "zstd: factor common parts of set_zstd_error()"
This reverts commite02f66c.
  • Loading branch information
@AA-Turner
AA-Turner committedMay 8, 2025
commit663e6666905d20c15b39fa338e036851485fe50b
23 changes: 11 additions & 12 deletionsModules/_zstd/_zstdmodule.c
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -28,44 +28,43 @@ set_zstd_error(const _zstd_state* const state,
switch (type)
{
case ERR_DECOMPRESS:
msg = "decompress zstd data";
msg = "Unable todecompress zstd data: %s";
break;
case ERR_COMPRESS:
msg = "compress zstd data";
msg = "Unable tocompress zstd data: %s";
break;
case ERR_SET_PLEDGED_INPUT_SIZE:
msg = "set pledged uncompressed content size";
msg = "Unable toset pledged uncompressed content size: %s";
break;

case ERR_LOAD_D_DICT:
msg = "load zstd dictionary or prefix for decompression";
msg = "Unable toload zstd dictionary or prefix for decompression: %s";
break;
case ERR_LOAD_C_DICT:
msg = "load zstd dictionary or prefix for compression";
msg = "Unable toload zstd dictionary or prefix for compression: %s";
break;

case ERR_GET_C_BOUNDS:
msg = "get zstd compression parameter bounds";
msg = "Unable toget zstd compression parameter bounds: %s";
break;
case ERR_GET_D_BOUNDS:
msg = "get zstd decompression parameter bounds";
msg = "Unable toget zstd decompression parameter bounds: %s";
break;
case ERR_SET_C_LEVEL:
msg = "set zstd compression level";
msg = "Unable toset zstd compression level: %s";
break;

case ERR_TRAIN_DICT:
msg = "train zstd dictionary";
msg = "Unable totrain zstd dictionary: %s";
break;
case ERR_FINALIZE_DICT:
msg = "finalize zstd dictionary";
msg = "Unable tofinalize zstd dictionary: %s";
break;

default:
Py_UNREACHABLE();
}
PyErr_Format(state->ZstdError, "Unable to %s: %s",
msg, ZSTD_getErrorName(zstd_ret));
PyErr_Format(state->ZstdError, msg, ZSTD_getErrorName(zstd_ret));
}

typedef struct {
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp