Skip to content

Commit

Permalink
cast to PyCFunction
Browse files Browse the repository at this point in the history
  • Loading branch information
zariiii9003 committed Aug 11, 2024
1 parent d7cba8b commit c6c34c3
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 19 deletions.
15 changes: 9 additions & 6 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,12 @@ jobs:
fail-fast: false

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0 # fetch tags for setuptools-scm

# Used to host cibuildwheel
- uses: actions/setup-python@v4
# Used to host cibuildwhee
- uses: actions/setup-python@v5
with:
python-version: "3.10"

Expand All @@ -40,9 +42,10 @@ jobs:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v4
- uses: actions/checkout@v4
with:
fetch-depth: 0 # fetch tags for setuptools-scm
- uses: actions/setup-python@v5
with:
python-version: "3.10"

Expand Down
14 changes: 7 additions & 7 deletions src/e2e/crc.c
Original file line number Diff line number Diff line change
Expand Up @@ -495,31 +495,31 @@ py_calculate_crc64(PyObject *module,

static struct PyMethodDef methods[] = {
{"calculate_crc8",
py_calculate_crc8,
(PyCFunction)py_calculate_crc8,
METH_VARARGS | METH_KEYWORDS,
py_calculate_crc8_doc},
{"calculate_crc8_h2f",
py_calculate_crc8_h2f,
(PyCFunction)py_calculate_crc8_h2f,
METH_VARARGS | METH_KEYWORDS,
py_calculate_crc8_h2f_doc},
{"calculate_crc16",
py_calculate_crc16,
(PyCFunction)py_calculate_crc16,
METH_VARARGS | METH_KEYWORDS,
py_calculate_crc16_doc},
{"calculate_crc16_arc",
py_calculate_crc16_arc,
(PyCFunction)py_calculate_crc16_arc,
METH_VARARGS | METH_KEYWORDS,
py_calculate_crc16_arc_doc},
{"calculate_crc32",
py_calculate_crc32,
(PyCFunction)py_calculate_crc32,
METH_VARARGS | METH_KEYWORDS,
py_calculate_crc32_doc},
{"calculate_crc32_p4",
py_calculate_crc32_p4,
(PyCFunction)py_calculate_crc32_p4,
METH_VARARGS | METH_KEYWORDS,
py_calculate_crc32_p4_doc},
{"calculate_crc64",
py_calculate_crc64,
(PyCFunction)py_calculate_crc64,
METH_VARARGS | METH_KEYWORDS,
py_calculate_crc64_doc},
{NULL} // sentinel
Expand Down
4 changes: 2 additions & 2 deletions src/e2e/p01.c
Original file line number Diff line number Diff line change
Expand Up @@ -294,11 +294,11 @@ py_e2e_p01_check(PyObject *module,

static struct PyMethodDef methods[] = {
{"e2e_p01_protect",
py_e2e_p01_protect,
(PyCFunction)py_e2e_p01_protect,
METH_VARARGS | METH_KEYWORDS,
e2e_p01_protect_doc},
{"e2e_p01_check",
py_e2e_p01_check,
(PyCFunction)py_e2e_p01_check,
METH_VARARGS | METH_KEYWORDS,
e2e_p01_check_doc},
{NULL} // sentinel
Expand Down
4 changes: 2 additions & 2 deletions src/e2e/p02.c
Original file line number Diff line number Diff line change
Expand Up @@ -178,11 +178,11 @@ py_e2e_p02_check(PyObject *module,

static struct PyMethodDef methods[] = {
{"e2e_p02_protect",
py_e2e_p02_protect,
(PyCFunction)py_e2e_p02_protect,
METH_VARARGS | METH_KEYWORDS,
e2e_p02_protect_doc},
{"e2e_p02_check",
py_e2e_p02_check,
(PyCFunction)py_e2e_p02_check,
METH_VARARGS | METH_KEYWORDS,
e2e_p02_check_doc},
{NULL} // sentinel
Expand Down
4 changes: 2 additions & 2 deletions src/e2e/p05.c
Original file line number Diff line number Diff line change
Expand Up @@ -192,11 +192,11 @@ py_e2e_p05_check(PyObject *module,

static struct PyMethodDef methods[] = {
{"e2e_p05_protect",
py_e2e_p05_protect,
(PyCFunction)py_e2e_p05_protect,
METH_VARARGS | METH_KEYWORDS,
e2e_p05_protect_doc},
{"e2e_p05_check",
py_e2e_p05_check,
(PyCFunction)py_e2e_p05_check,
METH_VARARGS | METH_KEYWORDS,
e2e_p05_check_doc},
{NULL} // sentinel
Expand Down

0 comments on commit c6c34c3

Please sign in to comment.