*.pyx: Replace __new__ with __cinit__ like the program says.
[mLib-python] / codec.pyx.in
index e683233..971c899 100644 (file)
@@ -39,7 +39,7 @@ cdef extern from 'mLib/%PREFIX%.h':
 
 cdef class %CLASS%Encode:
   cdef %PREFIX%_ctx ctx
-  def __new__(me, *hunoz, **hukairz):
+  def __cinit__(me, *hunoz, **hukairz):
     _%PREFIX%_init(&me.ctx)
     me.ctx.indent = NULL
   def __init__(me, indent = '\n', maxline = 72):
@@ -90,7 +90,7 @@ def %PREFIX%_encode(text, *arg, **kw):
 
 cdef class %CLASS%Decode:
   cdef %PREFIX%_ctx ctx
-  def __new__(me, *hunoz, **hukairz):
+  def __cinit__(me, *hunoz, **hukairz):
     _%PREFIX%_init(&me.ctx)
     me.ctx.indent = NULL
   def decode(me, text):