chiark / gitweb /
array.c: Add fake initializations in `pop' and `shift' to muffle warnings.
[mLib-python] / lbuf.pyx
index fe9f00eb677a1988d5f470131df032bc1e80b517..b80b5ccccdea07060555af920bf03191b9b3aa1b 100644 (file)
--- a/lbuf.pyx
+++ b/lbuf.pyx
@@ -1,29 +1,27 @@
-# -*-pyrex-*-
-#
-# $Id$
-#
-# Line buffering
-#
-# (c) 2005 Straylight/Edgeware
-#
+### -*-pyrex-*-
+###
+### Line buffering
+###
+### (c) 2005 Straylight/Edgeware
+###
 
-#----- Licensing notice -----------------------------------------------------
-#
-# This file is part of the Python interface to mLib.
-#
-# mLib/Python is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# mLib/Python is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with mLib/Python; if not, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+###----- Licensing notice ---------------------------------------------------
+###
+### This file is part of the Python interface to mLib.
+###
+### mLib/Python is free software; you can redistribute it and/or modify
+### it under the terms of the GNU General Public License as published by
+### the Free Software Foundation; either version 2 of the License, or
+### (at your option) any later version.
+###
+### mLib/Python is distributed in the hope that it will be useful,
+### but WITHOUT ANY WARRANTY; without even the implied warranty of
+### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+### GNU General Public License for more details.
+###
+### You should have received a copy of the GNU General Public License
+### along with mLib/Python; if not, write to the Free Software Foundation,
+### Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
 LBUF_CRLF = _LBUF_CRLF
 LBUF_STRICTCRLF = _LBUF_STRICTCRLF
@@ -32,7 +30,7 @@ cdef class LineBuffer:
   cdef lbuf b
   cdef _line
   cdef _eof
-  def __new__(me, lineproc = None, eofproc = None, *hunoz, **hukairz):
+  def __cinit__(me, lineproc = None, eofproc = None, *hunoz, **hukairz):
     lbuf_init(&me.b, _lbfunc, <void *>me)
     me._line = _checkcallable(lineproc, 'line proc')
     me._eof = _checkcallable(eofproc, 'eof proc')
@@ -128,4 +126,4 @@ cdef void _lbfunc(char *s, size_t n, void *arg):
   else:
     sb.line(PyString_FromStringAndSize(s, n))
 
-#----- That's all, folks ----------------------------------------------------
+###----- That's all, folks --------------------------------------------------