aboutsummaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/nissy_module.c27
1 files changed, 0 insertions, 27 deletions
diff --git a/python/nissy_module.c b/python/nissy_module.c
index 58a5b67..5378c72 100644
--- a/python/nissy_module.c
+++ b/python/nissy_module.c
@@ -61,32 +61,6 @@ long_result(long long result)
61 return PyLong_FromLong(result); 61 return PyLong_FromLong(result);
62} 62}
63 63
64
65PyDoc_STRVAR(compose_doc,
66"compose(cube, permutation)\n"
67"--\n\n"
68"Apply 'permutation' on 'cube'.\n"
69"\n"
70"Parameters:\n"
71" - cube: a cube\n"
72" - permutation: another cube\n"
73"\n"
74"Returns: the resulting cube string\n"
75);
76static PyObject *
77compose(PyObject *self, PyObject *args)
78{
79 long long err;
80 const char *cube, *permutation;
81 char result[NISSY_SIZE_CUBE];
82
83 if (!PyArg_ParseTuple(args, "ss", &cube, &permutation))
84 return NULL;
85
86 err = nissy_compose(cube, permutation, result);
87 return string_result(err, result);
88}
89
90PyDoc_STRVAR(inverse_doc, 64PyDoc_STRVAR(inverse_doc,
91"inverse(cube)\n" 65"inverse(cube)\n"
92"--\n\n" 66"--\n\n"
@@ -368,7 +342,6 @@ countmoves(PyObject *self, PyObject *args)
368} 342}
369 343
370static PyMethodDef nissy_methods[] = { 344static PyMethodDef nissy_methods[] = {
371 { "compose", compose, METH_VARARGS, compose_doc },
372 { "inverse", inverse, METH_VARARGS, inverse_doc }, 345 { "inverse", inverse, METH_VARARGS, inverse_doc },
373 { "applymoves", applymoves, METH_VARARGS, applymoves_doc }, 346 { "applymoves", applymoves, METH_VARARGS, applymoves_doc },
374 { "applytrans", applytrans, METH_VARARGS, applytrans_doc }, 347 { "applytrans", applytrans, METH_VARARGS, applytrans_doc },

Generated with cgit - Back to sebastiano.tronto.net