[Python-modules-commits] r3887 - in packages/python-pysizer/trunk/python-pysizer/trunk (12 files)
stew-guest at users.alioth.debian.org
stew-guest at users.alioth.debian.org
Thu Dec 6 20:58:10 UTC 2007
Date: Thursday, December 6, 2007 @ 20:58:08
Author: stew-guest
Revision: 3887
[svn-inject] Applying Debian modifications to trunk
Added:
packages/python-pysizer/trunk/python-pysizer/trunk/debian/
packages/python-pysizer/trunk/python-pysizer/trunk/debian/changelog
packages/python-pysizer/trunk/python-pysizer/trunk/debian/compat
packages/python-pysizer/trunk/python-pysizer/trunk/debian/control
packages/python-pysizer/trunk/python-pysizer/trunk/debian/copyright
packages/python-pysizer/trunk/python-pysizer/trunk/debian/docs
packages/python-pysizer/trunk/python-pysizer/trunk/debian/pycompat
packages/python-pysizer/trunk/python-pysizer/trunk/debian/rules
packages/python-pysizer/trunk/python-pysizer/trunk/debian/watch
packages/python-pysizer/trunk/python-pysizer/trunk/src/
packages/python-pysizer/trunk/python-pysizer/trunk/src/cpython/
packages/python-pysizer/trunk/python-pysizer/trunk/src/cpython/crules.c
Property changes on: packages/python-pysizer/trunk/python-pysizer/trunk/debian
___________________________________________________________________
Name: mergeWithUpstream
+ 1
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/changelog
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/changelog (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/changelog 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1,5 @@
+python-pysizer (0.1.1-1) UNRELEASED; urgency=low
+
+ * Initial release. (Closes: #444221)
+
+ -- Mike O'Connor <stew at vireo.org> Thu, 06 Dec 2007 16:23:05 -0500
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/compat
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/compat (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/compat 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1 @@
+5
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/control
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/control (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/control 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1,23 @@
+Source: python-pysizer
+Section: python
+Priority: extra
+Maintainer: Debian Python Modules Team <python-modules-team at lists.alioth.debian.org>
+Uploaders: Mike O'Connor <stew at vireo.org>
+Build-Depends: debhelper (>= 5.0.37.2), python-all-dev (>= 2.3.5-11), python-pyrex
+Build-Depends-Indep: python-support (>= 0.3)
+Standards-Version: 3.7.3
+Homepage: http://pysizer.8325.org/
+Vcs-Svn: svn://svn.debian.org/python-modules/packages/python-sizer/trunk/
+Vcs-Browser: http://svn.debian.org/wsvn/python-modules/packages/python-sizer/?op=log
+
+Package: python-pysizer
+Architecture: any
+Depends: ${python:Depends}
+XB-Python-Version: ${python:Versions}
+Description: memory profiler for Python
+ PySizer lets you analyse the memory usage of your Python programs and
+ makes data such as memory usage by objects of a certain type readily
+ available.
+ This package contains the parts of PySizer written in Python. There
+ is an optional patch to python itself to collect more information, but
+ that has not been compiled into the stock Debian python binaries.
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/copyright
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/copyright (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/copyright 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1,72 @@
+This package was debianized by Mike O'Connor <stew at vireo.org> on
+Thu Dec 6 16:29:10 +0500
+
+It was downloaded from http://pysizer.8325.org
+
+Upstream Author: Nick Smallbone
+
+doc/dottex.sty has the following Copyright:
+
+Copyright (c) 2005, Lars Kotthoff <metalhead at metalhead.ws>
+
+Large portions of doc/dottex.sty copied from pdftex,
+Copyright (c) 2001-3, Radhakrishnan CV <cvr at river-valley.com>
+ Rajagopal CV <cvr3 at river-valley.com>
+ http://www.river-valley.com
+
+
+All other files in python-sizer
+
+Copyright (c) 2005, Nick Smallbone
+
+
+License:
+
+doc/dottex.sty is distrubuted under the terms of the GPL version 2.
+
+ This package 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; version 2 dated June, 1991.
+
+ This package 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 this package; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
+ MA 02110-1301, USA.
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL'.
+
+---
+
+All other files are distrubted under the following license:
+
+Copyright (c) 2005, Nick Smallbone
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification,are permitted provided that the following conditions are met:
+
+1. Redistributions of source code must retain the above copyright notice,
+ this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+3. The name of the author may not be used to endorse or promote products
+ derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/docs
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/docs (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/docs 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1,3 @@
+README
+doc/*html
+doc/*ps
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/pycompat
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/pycompat (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/pycompat 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1 @@
+2
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/rules
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/rules (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/rules 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1,63 @@
+#!/usr/bin/make -f
+#-*- makefile -*-
+# Made with the aid of dh_make, by Craig Small
+# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess.
+# Some lines taken from debmake, by Christoph Lameter.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+PYVERS:=$(shell pyversions -r)
+
+build: build-stamp
+build-stamp: $(QUILT_STAMPFN)
+ dh_testdir
+ set -e; \
+ for py in $(PYVERS); do \
+ $$py setup.py build; \
+ done
+ touch $@
+
+clean:
+ dh_testdir
+ dh_testroot
+ for py in $(PYVERS); do \
+ $$py setup.py clean; \
+ done
+ rm -f install-stamp build-stamp
+ find . -name \*.pyc | xargs rm -f
+ rm -rf build
+ dh_clean
+
+install: install-stamp
+install-stamp:
+ dh_testdir
+ dh_testroot
+ dh_clean -k
+ dh_installdirs
+ set -e; \
+ for py in $(PYVERS); do \
+ $$py setup.py install --root=debian/python-pysizer; \
+ done
+ dh_installdocs -A
+ dh_installexamples
+
+ touch install-stamp
+
+binary-arch: build install
+ dh_testdir
+ dh_testroot
+ dh_installchangelogs
+ dh_compress -X.py
+ dh_fixperms
+ dh_pysupport
+ dh_strip
+ dh_installdeb
+ dh_gencontrol
+ dh_md5sums
+ dh_builddeb
+
+binary-indep: build install
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install
Property changes on: packages/python-pysizer/trunk/python-pysizer/trunk/debian/rules
___________________________________________________________________
Name: svn:executable
+ *
Added: packages/python-pysizer/trunk/python-pysizer/trunk/debian/watch
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/debian/watch (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/debian/watch 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1,2 @@
+version=3
+http://pysizer.8325.org/dist/sizer-([\d.]*)\.tar.gz
Added: packages/python-pysizer/trunk/python-pysizer/trunk/src/cpython/crules.c
===================================================================
--- packages/python-pysizer/trunk/python-pysizer/trunk/src/cpython/crules.c (rev 0)
+++ packages/python-pysizer/trunk/python-pysizer/trunk/src/cpython/crules.c 2007-12-06 20:58:08 UTC (rev 3887)
@@ -0,0 +1,473 @@
+/* Generated by Pyrex 0.9.5.1a on Thu Dec 6 16:42:59 2007 */
+
+#include "Python.h"
+#include "structmember.h"
+#ifndef PY_LONG_LONG
+ #define PY_LONG_LONG LONG_LONG
+#endif
+#ifdef __cplusplus
+#define __PYX_EXTERN_C extern "C"
+#else
+#define __PYX_EXTERN_C extern
+#endif
+__PYX_EXTERN_C double pow(double, double);
+#include "object.h"
+#include "fileobject.h"
+
+
+typedef struct {PyObject **p; char *s;} __Pyx_InternTabEntry; /*proto*/
+typedef struct {PyObject **p; char *s; long n;} __Pyx_StringTabEntry; /*proto*/
+
+static PyObject *__pyx_m;
+static PyObject *__pyx_b;
+static int __pyx_lineno;
+static char *__pyx_filename;
+static char **__pyx_f;
+
+static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list); /*proto*/
+
+static PyObject *__Pyx_GetName(PyObject *dict, PyObject *name); /*proto*/
+
+static PyObject *__Pyx_CreateClass(PyObject *bases, PyObject *dict, PyObject *name, char *modname); /*proto*/
+
+static int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed, char *name); /*proto*/
+
+static int __Pyx_InternStrings(__Pyx_InternTabEntry *t); /*proto*/
+
+static int __Pyx_InitStrings(__Pyx_StringTabEntry *t); /*proto*/
+
+static PyTypeObject *__Pyx_ImportType(char *module_name, char *class_name, long size); /*proto*/
+
+static void __Pyx_AddTraceback(char *funcname); /*proto*/
+
+/* Declarations from crules */
+
+static PyTypeObject *__pyx_ptype_6crules_file = 0;
+
+
+/* Implementation of crules */
+
+static char (__pyx_k1[]) = "sizer.wrapper";
+static char (__pyx_k2[]) = "sizer.sizes";
+
+static PyObject *__pyx_n_sizer;
+static PyObject *__pyx_n_FileWrapper;
+static PyObject *__pyx_n_wrapper;
+static PyObject *__pyx_n_ObjectWrapper;
+static PyObject *__pyx_n___init__;
+static PyObject *__pyx_n_sizes;
+static PyObject *__pyx_n_type;
+
+static PyObject *__pyx_k1p;
+static PyObject *__pyx_k2p;
+
+static PyObject *__pyx_n_addchild;
+static PyObject *__pyx_n_size;
+
+static PyObject *__pyx_f_6crules_11FileWrapper___init__(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+static PyMethodDef __pyx_mdef_6crules_11FileWrapper___init__ = {"__init__", (PyCFunction)__pyx_f_6crules_11FileWrapper___init__, METH_VARARGS|METH_KEYWORDS, 0};
+static PyObject *__pyx_f_6crules_11FileWrapper___init__(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+ PyObject *__pyx_v_self = 0;
+ PyFileObject *__pyx_v_obj = 0;
+ PyObject *__pyx_v_diff;
+ PyObject *__pyx_r;
+ PyObject *__pyx_1 = 0;
+ PyObject *__pyx_2 = 0;
+ PyObject *__pyx_3 = 0;
+ static char *__pyx_argnames[] = {"self","obj",0};
+ if (!PyArg_ParseTupleAndKeywords(__pyx_args, __pyx_kwds, "OO", __pyx_argnames, &__pyx_v_self, &__pyx_v_obj)) return 0;
+ Py_INCREF(__pyx_v_self);
+ Py_INCREF(__pyx_v_obj);
+ __pyx_v_diff = Py_None; Py_INCREF(Py_None);
+ if (!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_obj), __pyx_ptype_6crules_file, 0, "obj")) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;}
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":23 */
+ __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_n_sizer); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 23; goto __pyx_L1;}
+ __pyx_2 = PyObject_GetAttr(__pyx_1, __pyx_n_wrapper); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 23; goto __pyx_L1;}
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+ __pyx_1 = PyObject_GetAttr(__pyx_2, __pyx_n_ObjectWrapper); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 23; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ __pyx_2 = PyObject_GetAttr(__pyx_1, __pyx_n___init__); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 23; goto __pyx_L1;}
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+ __pyx_1 = PyTuple_New(2); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 23; goto __pyx_L1;}
+ Py_INCREF(__pyx_v_self);
+ PyTuple_SET_ITEM(__pyx_1, 0, __pyx_v_self);
+ Py_INCREF(((PyObject *)__pyx_v_obj));
+ PyTuple_SET_ITEM(__pyx_1, 1, ((PyObject *)__pyx_v_obj));
+ __pyx_3 = PyObject_CallObject(__pyx_2, __pyx_1); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 23; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":24 */
+ __pyx_2 = PyObject_GetAttr(__pyx_v_self, __pyx_n_addchild); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 24; goto __pyx_L1;}
+ __pyx_1 = PyInt_FromLong(0); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 24; goto __pyx_L1;}
+ __pyx_3 = PyTuple_New(2); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 24; goto __pyx_L1;}
+ Py_INCREF(__pyx_v_obj->f_name);
+ PyTuple_SET_ITEM(__pyx_3, 0, __pyx_v_obj->f_name);
+ PyTuple_SET_ITEM(__pyx_3, 1, __pyx_1);
+ __pyx_1 = 0;
+ __pyx_1 = PyObject_CallObject(__pyx_2, __pyx_3); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 24; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":25 */
+ __pyx_2 = PyObject_GetAttr(__pyx_v_self, __pyx_n_addchild); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; goto __pyx_L1;}
+ __pyx_3 = PyInt_FromLong(0); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; goto __pyx_L1;}
+ __pyx_1 = PyTuple_New(2); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; goto __pyx_L1;}
+ Py_INCREF(__pyx_v_obj->f_mode);
+ PyTuple_SET_ITEM(__pyx_1, 0, __pyx_v_obj->f_mode);
+ PyTuple_SET_ITEM(__pyx_1, 1, __pyx_3);
+ __pyx_3 = 0;
+ __pyx_3 = PyObject_CallObject(__pyx_2, __pyx_1); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":26 */
+ __pyx_2 = PyObject_GetAttr(__pyx_v_self, __pyx_n_addchild); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 26; goto __pyx_L1;}
+ __pyx_1 = PyInt_FromLong(0); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 26; goto __pyx_L1;}
+ __pyx_3 = PyTuple_New(2); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 26; goto __pyx_L1;}
+ Py_INCREF(__pyx_v_obj->f_encoding);
+ PyTuple_SET_ITEM(__pyx_3, 0, __pyx_v_obj->f_encoding);
+ PyTuple_SET_ITEM(__pyx_3, 1, __pyx_1);
+ __pyx_1 = 0;
+ __pyx_1 = PyObject_CallObject(__pyx_2, __pyx_3); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 26; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":27 */
+ __pyx_2 = PyInt_FromLong((__pyx_v_obj->f_bufend - __pyx_v_obj->f_buf)); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 27; goto __pyx_L1;}
+ Py_DECREF(__pyx_v_diff);
+ __pyx_v_diff = __pyx_2;
+ __pyx_2 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":28 */
+ __pyx_3 = PyObject_GetAttr(__pyx_v_self, __pyx_n_size); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 28; goto __pyx_L1;}
+ __pyx_1 = PyNumber_Add(__pyx_3, __pyx_v_diff); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 28; goto __pyx_L1;}
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+ __pyx_2 = PyInt_FromLong(__pyx_v_obj->ob_type->tp_basicsize); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 28; goto __pyx_L1;}
+ __pyx_3 = PyNumber_Add(__pyx_1, __pyx_2); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 28; goto __pyx_L1;}
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ if (PyObject_SetAttr(__pyx_v_self, __pyx_n_size, __pyx_3) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 28; goto __pyx_L1;}
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+
+ __pyx_r = Py_None; Py_INCREF(Py_None);
+ goto __pyx_L0;
+ __pyx_L1:;
+ Py_XDECREF(__pyx_1);
+ Py_XDECREF(__pyx_2);
+ Py_XDECREF(__pyx_3);
+ __Pyx_AddTraceback("crules.FileWrapper.__init__");
+ __pyx_r = 0;
+ __pyx_L0:;
+ Py_DECREF(__pyx_v_diff);
+ Py_DECREF(__pyx_v_self);
+ Py_DECREF(__pyx_v_obj);
+ return __pyx_r;
+}
+
+static __Pyx_InternTabEntry __pyx_intern_tab[] = {
+ {&__pyx_n_FileWrapper, "FileWrapper"},
+ {&__pyx_n_ObjectWrapper, "ObjectWrapper"},
+ {&__pyx_n___init__, "__init__"},
+ {&__pyx_n_addchild, "addchild"},
+ {&__pyx_n_size, "size"},
+ {&__pyx_n_sizer, "sizer"},
+ {&__pyx_n_sizes, "sizes"},
+ {&__pyx_n_type, "type"},
+ {&__pyx_n_wrapper, "wrapper"},
+ {0, 0}
+};
+
+static __Pyx_StringTabEntry __pyx_string_tab[] = {
+ {&__pyx_k1p, __pyx_k1, sizeof(__pyx_k1)},
+ {&__pyx_k2p, __pyx_k2, sizeof(__pyx_k2)},
+ {0, 0, 0}
+};
+
+static struct PyMethodDef __pyx_methods[] = {
+ {0, 0, 0, 0}
+};
+
+static void __pyx_init_filenames(void); /*proto*/
+
+PyMODINIT_FUNC initcrules(void); /*proto*/
+PyMODINIT_FUNC initcrules(void) {
+ PyObject *__pyx_1 = 0;
+ PyObject *__pyx_2 = 0;
+ PyObject *__pyx_3 = 0;
+ PyObject *__pyx_4 = 0;
+ __pyx_init_filenames();
+ __pyx_m = Py_InitModule4("crules", __pyx_methods, 0, 0, PYTHON_API_VERSION);
+ if (!__pyx_m) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;};
+ __pyx_b = PyImport_AddModule("__builtin__");
+ if (!__pyx_b) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;};
+ if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;};
+ if (__Pyx_InternStrings(__pyx_intern_tab) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;};
+ if (__Pyx_InitStrings(__pyx_string_tab) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;};
+ __pyx_ptype_6crules_file = __Pyx_ImportType("__builtin__", "file", sizeof(PyFileObject)); if (!__pyx_ptype_6crules_file) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 13; goto __pyx_L1;}
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":5 */
+ __pyx_1 = __Pyx_Import(__pyx_k1p, 0); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;}
+ if (PyObject_SetAttr(__pyx_m, __pyx_n_sizer, __pyx_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;}
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":5 */
+ __pyx_1 = __Pyx_Import(__pyx_k2p, 0); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;}
+ if (PyObject_SetAttr(__pyx_m, __pyx_n_sizer, __pyx_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 5; goto __pyx_L1;}
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":21 */
+ __pyx_1 = PyDict_New(); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; goto __pyx_L1;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_n_sizer); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; goto __pyx_L1;}
+ __pyx_3 = PyObject_GetAttr(__pyx_2, __pyx_n_wrapper); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ __pyx_2 = PyObject_GetAttr(__pyx_3, __pyx_n_ObjectWrapper); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; goto __pyx_L1;}
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+ __pyx_3 = PyTuple_New(1); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; goto __pyx_L1;}
+ PyTuple_SET_ITEM(__pyx_3, 0, __pyx_2);
+ __pyx_2 = 0;
+ __pyx_2 = __Pyx_CreateClass(__pyx_3, __pyx_1, __pyx_n_FileWrapper, "crules"); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; goto __pyx_L1;}
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":22 */
+ __pyx_3 = PyCFunction_New(&__pyx_mdef_6crules_11FileWrapper___init__, 0); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;}
+ __pyx_4 = PyMethod_New(__pyx_3, 0, __pyx_2); if (!__pyx_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;}
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+ if (PyObject_SetAttr(__pyx_2, __pyx_n___init__, __pyx_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;}
+ Py_DECREF(__pyx_4); __pyx_4 = 0;
+ if (PyObject_SetAttr(__pyx_m, __pyx_n_FileWrapper, __pyx_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+
+ /* "/home/stew/src/python-pysizer/python-pysizer-0.1.1/src/cpython/crules.pyx":30 */
+ __pyx_3 = __Pyx_GetName(__pyx_m, __pyx_n_FileWrapper); if (!__pyx_3) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 30; goto __pyx_L1;}
+ __pyx_4 = __Pyx_GetName(__pyx_m, __pyx_n_sizer); if (!__pyx_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 30; goto __pyx_L1;}
+ __pyx_2 = PyObject_GetAttr(__pyx_4, __pyx_n_sizes); if (!__pyx_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 30; goto __pyx_L1;}
+ Py_DECREF(__pyx_4); __pyx_4 = 0;
+ __pyx_1 = PyObject_GetAttr(__pyx_2, __pyx_n_type); if (!__pyx_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 30; goto __pyx_L1;}
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
+ if (PyObject_SetItem(__pyx_1, ((PyObject*)__pyx_ptype_6crules_file), __pyx_3) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 30; goto __pyx_L1;}
+ Py_DECREF(__pyx_1); __pyx_1 = 0;
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+ return;
+ __pyx_L1:;
+ Py_XDECREF(__pyx_1);
+ Py_XDECREF(__pyx_2);
+ Py_XDECREF(__pyx_3);
+ Py_XDECREF(__pyx_4);
+ __Pyx_AddTraceback("crules");
+}
+
+static char *__pyx_filenames[] = {
+ "crules.pyx",
+};
+
+/* Runtime support code */
+
+static void __pyx_init_filenames(void) {
+ __pyx_f = __pyx_filenames;
+}
+
+static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list) {
+ PyObject *__import__ = 0;
+ PyObject *empty_list = 0;
+ PyObject *module = 0;
+ PyObject *global_dict = 0;
+ PyObject *empty_dict = 0;
+ PyObject *list;
+ __import__ = PyObject_GetAttrString(__pyx_b, "__import__");
+ if (!__import__)
+ goto bad;
+ if (from_list)
+ list = from_list;
+ else {
+ empty_list = PyList_New(0);
+ if (!empty_list)
+ goto bad;
+ list = empty_list;
+ }
+ global_dict = PyModule_GetDict(__pyx_m);
+ if (!global_dict)
+ goto bad;
+ empty_dict = PyDict_New();
+ if (!empty_dict)
+ goto bad;
+ module = PyObject_CallFunction(__import__, "OOOO",
+ name, global_dict, empty_dict, list);
+bad:
+ Py_XDECREF(empty_list);
+ Py_XDECREF(__import__);
+ Py_XDECREF(empty_dict);
+ return module;
+}
+
+static PyObject *__Pyx_GetName(PyObject *dict, PyObject *name) {
+ PyObject *result;
+ result = PyObject_GetAttr(dict, name);
+ if (!result)
+ PyErr_SetObject(PyExc_NameError, name);
+ return result;
+}
+
+static PyObject *__Pyx_CreateClass(
+ PyObject *bases, PyObject *dict, PyObject *name, char *modname)
+{
+ PyObject *py_modname;
+ PyObject *result = 0;
+
+ py_modname = PyString_FromString(modname);
+ if (!py_modname)
+ goto bad;
+ if (PyDict_SetItemString(dict, "__module__", py_modname) < 0)
+ goto bad;
+ result = PyClass_New(bases, dict, name);
+bad:
+ Py_XDECREF(py_modname);
+ return result;
+}
+
+static int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed, char *name) {
+ if (!type) {
+ PyErr_Format(PyExc_SystemError, "Missing type object");
+ return 0;
+ }
+ if ((none_allowed && obj == Py_None) || PyObject_TypeCheck(obj, type))
+ return 1;
+ PyErr_Format(PyExc_TypeError,
+ "Argument '%s' has incorrect type (expected %s, got %s)",
+ name, type->tp_name, obj->ob_type->tp_name);
+ return 0;
+}
+
+static int __Pyx_InternStrings(__Pyx_InternTabEntry *t) {
+ while (t->p) {
+ *t->p = PyString_InternFromString(t->s);
+ if (!*t->p)
+ return -1;
+ ++t;
+ }
+ return 0;
+}
+
+static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
+ while (t->p) {
+ *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
+ if (!*t->p)
+ return -1;
+ ++t;
+ }
+ return 0;
+}
+
+static PyTypeObject *__Pyx_ImportType(char *module_name, char *class_name,
+ long size)
+{
+ PyObject *py_module_name = 0;
+ PyObject *py_class_name = 0;
+ PyObject *py_name_list = 0;
+ PyObject *py_module = 0;
+ PyObject *result = 0;
+
+ py_module_name = PyString_FromString(module_name);
+ if (!py_module_name)
+ goto bad;
+ py_class_name = PyString_FromString(class_name);
+ if (!py_class_name)
+ goto bad;
+ py_name_list = PyList_New(1);
+ if (!py_name_list)
+ goto bad;
+ Py_INCREF(py_class_name);
+ if (PyList_SetItem(py_name_list, 0, py_class_name) < 0)
+ goto bad;
+ py_module = __Pyx_Import(py_module_name, py_name_list);
+ if (!py_module)
+ goto bad;
+ result = PyObject_GetAttr(py_module, py_class_name);
+ if (!result)
+ goto bad;
+ if (!PyType_Check(result)) {
+ PyErr_Format(PyExc_TypeError,
+ "%s.%s is not a type object",
+ module_name, class_name);
+ goto bad;
+ }
+ if (((PyTypeObject *)result)->tp_basicsize != size) {
+ PyErr_Format(PyExc_ValueError,
+ "%s.%s does not appear to be the correct type object",
+ module_name, class_name);
+ goto bad;
+ }
+ goto done;
+bad:
+ Py_XDECREF(result);
+ result = 0;
+done:
+ Py_XDECREF(py_module_name);
+ Py_XDECREF(py_class_name);
+ Py_XDECREF(py_name_list);
+ return (PyTypeObject *)result;
+}
+
+#include "compile.h"
+#include "frameobject.h"
+#include "traceback.h"
+
+static void __Pyx_AddTraceback(char *funcname) {
+ PyObject *py_srcfile = 0;
+ PyObject *py_funcname = 0;
+ PyObject *py_globals = 0;
+ PyObject *empty_tuple = 0;
+ PyObject *empty_string = 0;
+ PyCodeObject *py_code = 0;
+ PyFrameObject *py_frame = 0;
+
+ py_srcfile = PyString_FromString(__pyx_filename);
+ if (!py_srcfile) goto bad;
+ py_funcname = PyString_FromString(funcname);
+ if (!py_funcname) goto bad;
+ py_globals = PyModule_GetDict(__pyx_m);
+ if (!py_globals) goto bad;
+ empty_tuple = PyTuple_New(0);
+ if (!empty_tuple) goto bad;
+ empty_string = PyString_FromString("");
+ if (!empty_string) goto bad;
+ py_code = PyCode_New(
+ 0, /*int argcount,*/
+ 0, /*int nlocals,*/
+ 0, /*int stacksize,*/
+ 0, /*int flags,*/
+ empty_string, /*PyObject *code,*/
+ empty_tuple, /*PyObject *consts,*/
+ empty_tuple, /*PyObject *names,*/
+ empty_tuple, /*PyObject *varnames,*/
+ empty_tuple, /*PyObject *freevars,*/
+ empty_tuple, /*PyObject *cellvars,*/
+ py_srcfile, /*PyObject *filename,*/
+ py_funcname, /*PyObject *name,*/
+ __pyx_lineno, /*int firstlineno,*/
+ empty_string /*PyObject *lnotab*/
+ );
+ if (!py_code) goto bad;
+ py_frame = PyFrame_New(
+ PyThreadState_Get(), /*PyThreadState *tstate,*/
+ py_code, /*PyCodeObject *code,*/
+ py_globals, /*PyObject *globals,*/
+ 0 /*PyObject *locals*/
+ );
+ if (!py_frame) goto bad;
+ py_frame->f_lineno = __pyx_lineno;
+ PyTraceBack_Here(py_frame);
+bad:
+ Py_XDECREF(py_srcfile);
+ Py_XDECREF(py_funcname);
+ Py_XDECREF(empty_tuple);
+ Py_XDECREF(empty_string);
+ Py_XDECREF(py_code);
+ Py_XDECREF(py_frame);
+}
More information about the Python-modules-commits
mailing list