Skip to content

Commit

Permalink
Remove version_compare3, deprecated in libversion
Browse files Browse the repository at this point in the history
  • Loading branch information
AMDmi3 committed Oct 29, 2018
1 parent bf6e739 commit f5eb493
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 22 deletions.
6 changes: 0 additions & 6 deletions demos/competitors.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,6 @@
'libversion.version_compare2({}, {})', '0',
2_600_000
),
(
'libversion.version_compare3', None,
'import libversion',
'libversion.version_compare3({}, {}, 0)', '0',
2_600_000
),
(
'libversion.version_compare4', None,
'import libversion',
Expand Down
3 changes: 1 addition & 2 deletions libversion/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,13 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.

from libversion._libversion import ANY_IS_PATCH, P_IS_PATCH, version_compare, version_compare2, version_compare3, version_compare4
from libversion._libversion import ANY_IS_PATCH, P_IS_PATCH, version_compare, version_compare2, version_compare4


__version__ = '1.1.0'

__all__ = [
'version_compare2',
'version_compare3',
'version_compare4',
'version_compare',

Expand Down
14 changes: 0 additions & 14 deletions src/_libversion.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,6 @@ static PyObject* py_version_compare2(PyObject *self, PyObject *args) {
return PyLong_FromLong(version_compare2(v1, v2));
}

static PyObject* py_version_compare3(PyObject *self, PyObject *args) {
(void)self; // (unused)

const char *v1;
const char *v2;
int flags;

if (!PyArg_ParseTuple(args, "ssi", &v1, &v2, &flags))
return NULL;

return PyLong_FromLong(version_compare3(v1, v2, flags));
}

static PyObject* py_version_compare4(PyObject *self, PyObject *args) {
(void)self; // (unused)

Expand Down Expand Up @@ -78,7 +65,6 @@ static PyObject* py_version_compare(PyObject *self, PyObject *args) {

static PyMethodDef module_methods[] = {
{"version_compare2", (PyCFunction)py_version_compare2, METH_VARARGS, ""},
{"version_compare3", (PyCFunction)py_version_compare3, METH_VARARGS, ""},
{"version_compare4", (PyCFunction)py_version_compare4, METH_VARARGS, ""},
{"version_compare", (PyCFunction)py_version_compare, METH_VARARGS, ""},
{NULL, NULL, 0, NULL}
Expand Down

0 comments on commit f5eb493

Please sign in to comment.