Mercurial > cpython-lru_cache-weakref
diff Objects/sliceobject.c @ 13458:7908ec855665 legacy-trunk
ANSI-fication of the sources.
| author | Fred Drake <fdrake@acm.org> |
|---|---|
| date | Sun, 09 Jul 2000 06:21:27 +0000 |
| parents | 1c7c2dd1beb1 |
| children | 35e8a29e5488 |
line wrap: on
line diff
--- a/Objects/sliceobject.c Sun Jul 09 06:03:25 2000 +0000 +++ b/Objects/sliceobject.c Sun Jul 09 06:21:27 2000 +0000 @@ -16,8 +16,7 @@ #include "Python.h" static PyObject * -ellipsis_repr(op) - PyObject *op; +ellipsis_repr(PyObject *op) { return PyString_FromString("Ellipsis"); } @@ -52,10 +51,7 @@ */ PyObject * -PySlice_New(start, stop, step) - PyObject *start; - PyObject *stop; - PyObject *step; +PySlice_New(PyObject *start, PyObject *stop, PyObject *step) { PySliceObject *obj = PyObject_NEW(PySliceObject, &PySlice_Type); @@ -74,12 +70,8 @@ } int -PySlice_GetIndices(r, length, start, stop, step) - PySliceObject *r; - int length; - int *start; - int *stop; - int *step; +PySlice_GetIndices(PySliceObject *r, int length, + int *start, int *stop, int *step) { if (r->step == Py_None) { *step = 1; @@ -108,8 +100,7 @@ } static void -slice_dealloc(r) - PySliceObject *r; +slice_dealloc(PySliceObject *r) { Py_DECREF(r->step); Py_DECREF(r->start); @@ -118,8 +109,7 @@ } static PyObject * -slice_repr(r) - PySliceObject *r; +slice_repr(PySliceObject *r) { PyObject *s, *comma; @@ -136,9 +126,7 @@ } -static PyObject *slice_getattr(self, name) - PySliceObject *self; - char *name; +static PyObject *slice_getattr(PySliceObject *self, char *name) { PyObject *ret;
