|
From: <js...@us...> - 2008-08-08 01:46:36
|
Revision: 6000
http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6000&view=rev
Author: jswhit
Date: 2008-08-08 01:46:33 +0000 (Fri, 08 Aug 2008)
Log Message:
-----------
backward compat fix for geos < 3
Modified Paths:
--------------
trunk/toolkits/basemap/src/_geoslib.c
Modified: trunk/toolkits/basemap/src/_geoslib.c
===================================================================
--- trunk/toolkits/basemap/src/_geoslib.c 2008-08-07 22:20:01 UTC (rev 5999)
+++ trunk/toolkits/basemap/src/_geoslib.c 2008-08-08 01:46:33 UTC (rev 6000)
@@ -1,4 +1,4 @@
-/* Generated by Cython 0.9.8 on Thu Aug 7 16:03:59 2008 */
+/* Generated by Cython 0.9.6.13.1 on Thu Aug 7 18:33:33 2008 */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
@@ -6,12 +6,6 @@
#ifndef PY_LONG_LONG
#define PY_LONG_LONG LONG_LONG
#endif
-#ifndef DL_EXPORT
- #define DL_EXPORT(t) t
-#endif
-#if PY_VERSION_HEX < 0x02040000
- #define METH_COEXIST 0
-#endif
#if PY_VERSION_HEX < 0x02050000
typedef int Py_ssize_t;
#define PY_SSIZE_T_MAX INT_MAX
@@ -21,69 +15,9 @@
#define PyNumber_Index(o) PyNumber_Int(o)
#define PyIndex_Check(o) PyNumber_Check(o)
#endif
-#if PY_VERSION_HEX < 0x02060000
- #define Py_REFCNT(ob) (((PyObject*)(ob))->ob_refcnt)
- #define Py_TYPE(ob) (((PyObject*)(ob))->ob_type)
- #define Py_SIZE(ob) ((PyVarObject*)(ob))->ob_size)
- #define PyVarObject_HEAD_INIT(type, size) \
- PyObject_HEAD_INIT(type) size,
-
- typedef struct {
- void *buf;
- Py_ssize_t len;
- int readonly;
- const char *format;
- int ndim;
- Py_ssize_t *shape;
- Py_ssize_t *strides;
- Py_ssize_t *suboffsets;
- Py_ssize_t itemsize;
- void *internal;
- } Py_buffer;
-
- #define PyBUF_SIMPLE 0
- #define PyBUF_WRITABLE 0x0001
- #define PyBUF_LOCK 0x0002
- #define PyBUF_FORMAT 0x0004
- #define PyBUF_ND 0x0008
- #define PyBUF_STRIDES (0x0010 | PyBUF_ND)
- #define PyBUF_C_CONTIGUOUS (0x0020 | PyBUF_STRIDES)
- #define PyBUF_F_CONTIGUOUS (0x0040 | PyBUF_STRIDES)
- #define PyBUF_ANY_CONTIGUOUS (0x0080 | PyBUF_STRIDES)
- #define PyBUF_INDIRECT (0x0100 | PyBUF_STRIDES)
+#if PY_VERSION_HEX < 0x02040000
+ #define METH_COEXIST 0
#endif
-#if PY_MAJOR_VERSION < 3
- #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
-#else
- #define __Pyx_BUILTIN_MODULE_NAME "builtins"
-#endif
-#if PY_MAJOR_VERSION >= 3
- #define Py_TPFLAGS_CHECKTYPES 0
- #define Py_TPFLAGS_HAVE_INDEX 0
-#endif
-#if PY_MAJOR_VERSION >= 3
- #define PyBaseString_Type PyUnicode_Type
- #define PyString_Type PyBytes_Type
- #define PyInt_Type PyLong_Type
- #define PyInt_Check(op) PyLong_Check(op)
- #define PyInt_CheckExact(op) PyLong_CheckExact(op)
- #define PyInt_FromString PyLong_FromString
- #define PyInt_FromUnicode PyLong_FromUnicode
- #define PyInt_FromLong PyLong_FromLong
- #define PyInt_FromSize_t PyLong_FromSize_t
- #define PyInt_FromSsize_t PyLong_FromSsize_t
- #define PyInt_AsLong PyLong_AsLong
- #define PyInt_AS_LONG PyLong_AS_LONG
- #define PyInt_AsSsize_t PyLong_AsSsize_t
- #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask
- #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
- #define PyNumber_Divide(x,y) PyNumber_TrueDivide(x,y)
-#else
- #define PyBytes_Type PyString_Type
-#endif
-#if PY_MAJOR_VERSION >= 3
- #define PyMethod_New(func, self, klass) PyInstanceMethod_New(func)
-#endif
#ifndef __stdcall
#define __stdcall
#endif
@@ -96,7 +30,6 @@
#define __PYX_EXTERN_C extern
#endif
#include <math.h>
-#define __PYX_HAVE_API___geoslib
#include "numpy/arrayobject.h"
#include "geos_c.h"
@@ -109,7 +42,8 @@
#define INLINE
#endif
-typedef struct {PyObject **p; char *s; long n; char is_unicode; char intern; char is_identifier;} __Pyx_StringTabEntry; /*proto*/
+typedef struct {PyObject **p; char *s;} __Pyx_InternTabEntry; /*proto*/
+typedef struct {PyObject **p; char *s; long n; int is_unicode;} __Pyx_StringTabEntry; /*proto*/
@@ -118,14 +52,6 @@
/* Type Conversion Predeclarations */
-#if PY_MAJOR_VERSION < 3
-#define __Pyx_PyBytes_FromString PyString_FromString
-#define __Pyx_PyBytes_AsString PyString_AsString
-#else
-#define __Pyx_PyBytes_FromString PyBytes_FromString
-#define __Pyx_PyBytes_AsString PyBytes_AsString
-#endif
-
#define __Pyx_PyBool_FromLong(b) ((b) ? (Py_INCREF(Py_True), Py_True) : (Py_INCREF(Py_False), Py_False))
static INLINE int __Pyx_PyObject_IsTrue(PyObject* x);
static INLINE PY_LONG_LONG __pyx_PyInt_AsLongLong(PyObject* x);
@@ -165,11 +91,11 @@
static PyObject *__pyx_empty_tuple;
static int __pyx_lineno;
static int __pyx_clineno = 0;
-static const char * __pyx_cfilenm= __FILE__;
-static const char *__pyx_filename;
-static const char **__pyx_f;
+static char * __pyx_cfilenm= __FILE__;
+static char *__pyx_filename;
+static char **__pyx_f;
-static int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed, char *name, int exact); /*proto*/
+static int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed, char *name); /*proto*/
static INLINE void __Pyx_RaiseArgtupleTooLong(Py_ssize_t num_expected, Py_ssize_t num_found); /*proto*/
@@ -179,59 +105,30 @@
static PyObject *__Pyx_GetName(PyObject *dict, PyObject *name); /*proto*/
-static void __Pyx_WriteUnraisable(const char *name); /*proto*/
+static void __Pyx_WriteUnraisable(char *name); /*proto*/
-static INLINE PyObject* __Pyx_PyObject_Append(PyObject* L, PyObject* x) {
- if (likely(PyList_CheckExact(L))) {
- if (PyList_Append(L, x) < 0) return NULL;
- Py_INCREF(Py_None);
- return Py_None; // this is just to have an accurate signature
- }
- else {
- return PyObject_CallMethod(L, "append", "(O)", x);
- }
-}
-
static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb); /*proto*/
static int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type); /*proto*/
-static INLINE PyObject *__Pyx_GetItemInt(PyObject *o, Py_ssize_t i, int is_unsigned) {
- PyObject *r;
- if (PyList_CheckExact(o) && 0 <= i && i < PyList_GET_SIZE(o)) {
- r = PyList_GET_ITEM(o, i);
- Py_INCREF(r);
- }
- else if (PyTuple_CheckExact(o) && 0 <= i && i < PyTuple_GET_SIZE(o)) {
- r = PyTuple_GET_ITEM(o, i);
- Py_INCREF(r);
- }
- else if (Py_TYPE(o)->tp_as_sequence && Py_TYPE(o)->tp_as_sequence->sq_item && (likely(i >= 0) || !is_unsigned))
- r = PySequence_GetItem(o, i);
- else {
- PyObject *j = (likely(i >= 0) || !is_unsigned) ? PyInt_FromLong(i) : PyLong_FromUnsignedLongLong((sizeof(unsigned long long) > sizeof(Py_ssize_t) ? (1ULL << (sizeof(Py_ssize_t)*8)) : 0) + i);
- if (!j)
- return 0;
- r = PyObject_GetItem(o, j);
- Py_DECREF(j);
- }
- return r;
-}
+static int __Pyx_InternStrings(__Pyx_InternTabEntry *t); /*proto*/
static int __Pyx_InitStrings(__Pyx_StringTabEntry *t); /*proto*/
+static int __Pyx_ExportFunction(char *n, void *f, char *s); /*proto*/
+
static PyTypeObject *__Pyx_ImportType(char *module_name, char *class_name, long size); /*proto*/
static PyObject *__Pyx_ImportModule(char *name); /*proto*/
-static void __Pyx_AddTraceback(const char *funcname); /*proto*/
+static void __Pyx_AddTraceback(char *funcname); /*proto*/
-/* Type declarations */
+/* Declarations */
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":128
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":128
* initGEOS(notice_h, error_h)
*
- * cdef class BaseGeometry: # <<<<<<<<<<<<<<
+ * cdef class BaseGeometry: # <<<<<<<<<<<<<<
* cdef GEOSGeom *_geom
* cdef unsigned int _npts
*/
@@ -243,11 +140,11 @@
PyObject *boundary;
};
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":253
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":253
* return (self.__class__,(self.boundary,))
+ *
+ * cdef class Polygon(BaseGeometry): # <<<<<<<<<<<<<<
*
- * cdef class Polygon(BaseGeometry): # <<<<<<<<<<<<<<
- *
* def __init__(self, ndarray b):
*/
@@ -255,10 +152,10 @@
struct __pyx_obj_8_geoslib_BaseGeometry __pyx_base;
};
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":309
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":309
* return area
*
- * cdef class LineString(BaseGeometry): # <<<<<<<<<<<<<<
+ * cdef class LineString(BaseGeometry): # <<<<<<<<<<<<<<
* def __init__(self, ndarray b):
* cdef double dx, dy
*/
@@ -267,10 +164,10 @@
struct __pyx_obj_8_geoslib_BaseGeometry __pyx_base;
};
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":341
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":341
* self.boundary = b
*
- * cdef class Point(BaseGeometry): # <<<<<<<<<<<<<<
+ * cdef class Point(BaseGeometry): # <<<<<<<<<<<<<<
* cdef public x,y
* def __init__(self, b):
*/
@@ -280,9 +177,7 @@
PyObject *x;
PyObject *y;
};
-/* Module declarations from numpy */
-/* Module declarations from _geoslib */
static PyTypeObject *__pyx_ptype_8_geoslib_ndarray = 0;
static PyTypeObject *__pyx_ptype_8_geoslib_BaseGeometry = 0;
@@ -297,60 +192,41 @@
/* Implementation of _geoslib */
-static char __pyx_k_1[] = "0.1";
+static char __pyx_k_3[] = "0.1";
-static char __pyx_k_is_valid[] = "is_valid";
-static char __pyx_k_geom_type[] = "geom_type";
-static char __pyx_k_within[] = "within";
-static char __pyx_k_simplify[] = "simplify";
-static char __pyx_k_intersects[] = "intersects";
-static char __pyx_k_intersection[] = "intersection";
-static char __pyx_k_get_coords[] = "get_coords";
-static char __pyx_k___dealloc__[] = "__dealloc__";
-static char __pyx_k___reduce__[] = "__reduce__";
-static char __pyx_k___init__[] = "__init__";
-static char __pyx_k_area[] = "area";
-static char __pyx_k_sys[] = "sys";
-static char __pyx_k_numpy[] = "numpy";
-static char __pyx_k___version__[] = "__version__";
-static char __pyx_k___geos_version__[] = "__geos_version__";
+static PyObject *__pyx_n_is_valid;
+static PyObject *__pyx_n_geom_type;
+static PyObject *__pyx_n_within;
+static PyObject *__pyx_n_simplify;
+static PyObject *__pyx_n_intersects;
+static PyObject *__pyx_n_intersection;
+static PyObject *__pyx_n_get_coords;
+static PyObject *__pyx_n___dealloc__;
+static PyObject *__pyx_n___reduce__;
+static PyObject *__pyx_n___init__;
+static PyObject *__pyx_n_area;
+static PyObject *__pyx_n_sys;
+static PyObject *__pyx_n_numpy;
+static PyObject *__pyx_n___version__;
+static PyObject *__pyx_n___geos_version__;
-static PyObject *__pyx_kp_is_valid;
-static PyObject *__pyx_kp_geom_type;
-static PyObject *__pyx_kp_within;
-static PyObject *__pyx_kp_simplify;
-static PyObject *__pyx_kp_intersects;
-static PyObject *__pyx_kp_intersection;
-static PyObject *__pyx_kp_get_coords;
-static PyObject *__pyx_kp___dealloc__;
-static PyObject *__pyx_kp___reduce__;
-static PyObject *__pyx_kp___init__;
-static PyObject *__pyx_kp_area;
-static PyObject *__pyx_kp_sys;
-static PyObject *__pyx_kp_numpy;
-static PyObject *__pyx_kp___version__;
-static PyObject *__pyx_kp___geos_version__;
+static PyObject *__pyx_k_3p;
-static PyObject *__pyx_kp_1;
-
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":101
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":101
* int GEOSCoordSeq_getSize(GEOSCoordSeq *s, unsigned int *size)
*
- * cdef void notice_h(char *fmt, char*msg): # <<<<<<<<<<<<<<
+ * cdef void notice_h(char *fmt, char*msg): # <<<<<<<<<<<<<<
* format = PyString_FromString(fmt)
* message = PyString_FromString(msg)
*/
-static char __pyx_k_stdout[] = "stdout";
-static char __pyx_k_write[] = "write";
+static PyObject *__pyx_n_stdout;
+static PyObject *__pyx_n_write;
-static PyObject *__pyx_kp_stdout;
-static PyObject *__pyx_kp_write;
+static PyObject *__pyx_k_4p;
-static PyObject *__pyx_kp_2;
+static char __pyx_k_4[] = "GEOS_NOTICE: %s\n";
-static char __pyx_k_2[] = "GEOS_NOTICE: %s\n";
-
static void __pyx_f_8_geoslib_notice_h(char *__pyx_v_fmt, char *__pyx_v_msg) {
PyObject *__pyx_v_format;
PyObject *__pyx_v_message;
@@ -362,10 +238,10 @@
__pyx_v_message = Py_None; Py_INCREF(Py_None);
__pyx_v_warn_msg = Py_None; Py_INCREF(Py_None);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":102
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":102
*
* cdef void notice_h(char *fmt, char*msg):
- * format = PyString_FromString(fmt) # <<<<<<<<<<<<<<
+ * format = PyString_FromString(fmt) # <<<<<<<<<<<<<<
* message = PyString_FromString(msg)
* try:
*/
@@ -374,10 +250,10 @@
__pyx_v_format = __pyx_1;
__pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":103
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":103
* cdef void notice_h(char *fmt, char*msg):
* format = PyString_FromString(fmt)
- * message = PyString_FromString(msg) # <<<<<<<<<<<<<<
+ * message = PyString_FromString(msg) # <<<<<<<<<<<<<<
* try:
* warn_msg = format % message
*/
@@ -386,19 +262,19 @@
__pyx_v_message = __pyx_1;
__pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":104
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":104
* format = PyString_FromString(fmt)
* message = PyString_FromString(msg)
- * try: # <<<<<<<<<<<<<<
+ * try: # <<<<<<<<<<<<<<
* warn_msg = format % message
* except:
*/
/*try:*/ {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":105
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":105
* message = PyString_FromString(msg)
* try:
- * warn_msg = format % message # <<<<<<<<<<<<<<
+ * warn_msg = format % message # <<<<<<<<<<<<<<
* except:
* warn_msg = format
*/
@@ -411,10 +287,10 @@
__pyx_L2:;
Py_XDECREF(__pyx_1); __pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":106
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":106
* try:
* warn_msg = format % message
- * except: # <<<<<<<<<<<<<<
+ * except: # <<<<<<<<<<<<<<
* warn_msg = format
* sys.stdout.write('GEOS_NOTICE: %s\n' % warn_msg)
*/
@@ -422,10 +298,10 @@
__Pyx_AddTraceback("_geoslib.notice_h");
if (__Pyx_GetException(&__pyx_1, &__pyx_2, &__pyx_3) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1;}
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":107
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":107
* warn_msg = format % message
* except:
- * warn_msg = format # <<<<<<<<<<<<<<
+ * warn_msg = format # <<<<<<<<<<<<<<
* sys.stdout.write('GEOS_NOTICE: %s\n' % warn_msg)
*
*/
@@ -439,25 +315,25 @@
}
__pyx_L3:;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":108
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":108
* except:
* warn_msg = format
- * sys.stdout.write('GEOS_NOTICE: %s\n' % warn_msg) # <<<<<<<<<<<<<<
+ * sys.stdout.write('GEOS_NOTICE: %s\n' % warn_msg) # <<<<<<<<<<<<<<
*
* cdef void error_h(char *fmt, char*msg):
*/
- __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_sys); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
- __pyx_2 = PyObject_GetAttr(__pyx_1, __pyx_kp_stdout); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_n_sys); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_2 = PyObject_GetAttr(__pyx_1, __pyx_n_stdout); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_1); __pyx_1 = 0;
- __pyx_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_write); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_3 = PyObject_GetAttr(__pyx_2, __pyx_n_write); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_2); __pyx_2 = 0;
- __pyx_1 = PyNumber_Remainder(__pyx_kp_2, __pyx_v_warn_msg); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_1 = PyNumber_Remainder(__pyx_k_4p, __pyx_v_warn_msg); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
__pyx_2 = PyTuple_New(1); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
PyTuple_SET_ITEM(__pyx_2, 0, __pyx_1);
__pyx_1 = 0;
- __pyx_1 = PyObject_Call(__pyx_3, ((PyObject *)__pyx_2), NULL); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_1 = PyObject_Call(__pyx_3, __pyx_2, NULL); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_3); __pyx_3 = 0;
- Py_DECREF(((PyObject *)__pyx_2)); __pyx_2 = 0;
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
Py_DECREF(__pyx_1); __pyx_1 = 0;
goto __pyx_L0;
@@ -472,22 +348,20 @@
Py_DECREF(__pyx_v_warn_msg);
}
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":110
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":110
* sys.stdout.write('GEOS_NOTICE: %s\n' % warn_msg)
*
- * cdef void error_h(char *fmt, char*msg): # <<<<<<<<<<<<<<
+ * cdef void error_h(char *fmt, char*msg): # <<<<<<<<<<<<<<
* format = PyString_FromString(fmt)
* message = PyString_FromString(msg)
*/
-static char __pyx_k_stderr[] = "stderr";
+static PyObject *__pyx_n_stderr;
-static PyObject *__pyx_kp_stderr;
+static PyObject *__pyx_k_5p;
-static PyObject *__pyx_kp_3;
+static char __pyx_k_5[] = "GEOS_ERROR: %s\n";
-static char __pyx_k_3[] = "GEOS_ERROR: %s\n";
-
static void __pyx_f_8_geoslib_error_h(char *__pyx_v_fmt, char *__pyx_v_msg) {
PyObject *__pyx_v_format;
PyObject *__pyx_v_message;
@@ -499,10 +373,10 @@
__pyx_v_message = Py_None; Py_INCREF(Py_None);
__pyx_v_warn_msg = Py_None; Py_INCREF(Py_None);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":111
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":111
*
* cdef void error_h(char *fmt, char*msg):
- * format = PyString_FromString(fmt) # <<<<<<<<<<<<<<
+ * format = PyString_FromString(fmt) # <<<<<<<<<<<<<<
* message = PyString_FromString(msg)
* try:
*/
@@ -511,10 +385,10 @@
__pyx_v_format = __pyx_1;
__pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":112
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":112
* cdef void error_h(char *fmt, char*msg):
* format = PyString_FromString(fmt)
- * message = PyString_FromString(msg) # <<<<<<<<<<<<<<
+ * message = PyString_FromString(msg) # <<<<<<<<<<<<<<
* try:
* warn_msg = format % message
*/
@@ -523,19 +397,19 @@
__pyx_v_message = __pyx_1;
__pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":113
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":113
* format = PyString_FromString(fmt)
* message = PyString_FromString(msg)
- * try: # <<<<<<<<<<<<<<
+ * try: # <<<<<<<<<<<<<<
* warn_msg = format % message
* except:
*/
/*try:*/ {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":114
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":114
* message = PyString_FromString(msg)
* try:
- * warn_msg = format % message # <<<<<<<<<<<<<<
+ * warn_msg = format % message # <<<<<<<<<<<<<<
* except:
* warn_msg = format
*/
@@ -548,10 +422,10 @@
__pyx_L2:;
Py_XDECREF(__pyx_1); __pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":115
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":115
* try:
* warn_msg = format % message
- * except: # <<<<<<<<<<<<<<
+ * except: # <<<<<<<<<<<<<<
* warn_msg = format
* sys.stderr.write('GEOS_ERROR: %s\n' % warn_msg)
*/
@@ -559,10 +433,10 @@
__Pyx_AddTraceback("_geoslib.error_h");
if (__Pyx_GetException(&__pyx_1, &__pyx_2, &__pyx_3) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1;}
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":116
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":116
* warn_msg = format % message
* except:
- * warn_msg = format # <<<<<<<<<<<<<<
+ * warn_msg = format # <<<<<<<<<<<<<<
* sys.stderr.write('GEOS_ERROR: %s\n' % warn_msg)
*
*/
@@ -576,25 +450,25 @@
}
__pyx_L3:;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":117
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":117
* except:
* warn_msg = format
- * sys.stderr.write('GEOS_ERROR: %s\n' % warn_msg) # <<<<<<<<<<<<<<
+ * sys.stderr.write('GEOS_ERROR: %s\n' % warn_msg) # <<<<<<<<<<<<<<
*
* # check library version
*/
- __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_sys); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
- __pyx_2 = PyObject_GetAttr(__pyx_1, __pyx_kp_stderr); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_n_sys); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_2 = PyObject_GetAttr(__pyx_1, __pyx_n_stderr); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_1); __pyx_1 = 0;
- __pyx_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_write); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_3 = PyObject_GetAttr(__pyx_2, __pyx_n_write); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_2); __pyx_2 = 0;
- __pyx_1 = PyNumber_Remainder(__pyx_kp_3, __pyx_v_warn_msg); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_1 = PyNumber_Remainder(__pyx_k_5p, __pyx_v_warn_msg); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
__pyx_2 = PyTuple_New(1); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
PyTuple_SET_ITEM(__pyx_2, 0, __pyx_1);
__pyx_1 = 0;
- __pyx_1 = PyObject_Call(__pyx_3, ((PyObject *)__pyx_2), NULL); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_1 = PyObject_Call(__pyx_3, __pyx_2, NULL); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_3); __pyx_3 = 0;
- Py_DECREF(((PyObject *)__pyx_2)); __pyx_2 = 0;
+ Py_DECREF(__pyx_2); __pyx_2 = 0;
Py_DECREF(__pyx_1); __pyx_1 = 0;
goto __pyx_L0;
@@ -609,10 +483,10 @@
Py_DECREF(__pyx_v_warn_msg);
}
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":120
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":120
*
* # check library version
- * cdef geos_version(): # <<<<<<<<<<<<<<
+ * cdef geos_version(): # <<<<<<<<<<<<<<
* return PyString_FromString(GEOSversion())
* __geos_version__ = geos_version() # module variable.
*/
@@ -621,10 +495,10 @@
PyObject *__pyx_r;
PyObject *__pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":121
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":121
* # check library version
* cdef geos_version():
- * return PyString_FromString(GEOSversion()) # <<<<<<<<<<<<<<
+ * return PyString_FromString(GEOSversion()) # <<<<<<<<<<<<<<
* __geos_version__ = geos_version() # module variable.
* #if __geos_version__ != "2.2.3-CAPI-1.1.1":
*/
@@ -643,10 +517,10 @@
return __pyx_r;
}
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":133
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":133
* cdef public object boundary
*
- * def is_valid(self): # <<<<<<<<<<<<<<
+ * def is_valid(self): # <<<<<<<<<<<<<<
* cdef char valid
* valid = GEOSisValid(self._geom)
*/
@@ -657,29 +531,29 @@
PyObject *__pyx_r;
char __pyx_1;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":135
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":135
* def is_valid(self):
* cdef char valid
- * valid = GEOSisValid(self._geom) # <<<<<<<<<<<<<<
+ * valid = GEOSisValid(self._geom) # <<<<<<<<<<<<<<
* if valid:
* return True
*/
__pyx_v_valid = GEOSisValid(((struct __pyx_obj_8_geoslib_BaseGeometry *)__pyx_v_self)->_geom);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":136
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":136
* cdef char valid
* valid = GEOSisValid(self._geom)
- * if valid: # <<<<<<<<<<<<<<
+ * if valid: # <<<<<<<<<<<<<<
* return True
* else:
*/
__pyx_1 = __pyx_v_valid;
if (__pyx_1) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":137
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":137
* valid = GEOSisValid(self._geom)
* if valid:
- * return True # <<<<<<<<<<<<<<
+ * return True # <<<<<<<<<<<<<<
* else:
* return False
*/
@@ -690,10 +564,10 @@
}
/*else*/ {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":139
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":139
* return True
* else:
- * return False # <<<<<<<<<<<<<<
+ * return False # <<<<<<<<<<<<<<
*
* def geom_type(self):
*/
@@ -708,10 +582,10 @@
return __pyx_r;
}
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":141
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":141
* return False
*
- * def geom_type(self): # <<<<<<<<<<<<<<
+ * def geom_type(self): # <<<<<<<<<<<<<<
* return PyString_FromString(GEOSGeomType(self._geom))
*
*/
@@ -721,10 +595,10 @@
PyObject *__pyx_r;
PyObject *__pyx_1 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":142
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":142
*
* def geom_type(self):
- * return PyString_FromString(GEOSGeomType(self._geom)) # <<<<<<<<<<<<<<
+ * return PyString_FromString(GEOSGeomType(self._geom)) # <<<<<<<<<<<<<<
*
* def within(self, BaseGeometry geom):
*/
@@ -743,10 +617,10 @@
return __pyx_r;
}
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":144
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":144
* return PyString_FromString(GEOSGeomType(self._geom))
*
- * def within(self, BaseGeometry geom): # <<<<<<<<<<<<<<
+ * def within(self, BaseGeometry geom): # <<<<<<<<<<<<<<
* cdef GEOSGeom *g1, *g2
* cdef char answer
*/
@@ -758,49 +632,49 @@
char __pyx_v_answer;
PyObject *__pyx_r;
char __pyx_1;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_geom), __pyx_ptype_8_geoslib_BaseGeometry, 1, "geom", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_geom), __pyx_ptype_8_geoslib_BaseGeometry, 1, "geom"))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1;}
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":147
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":147
* cdef GEOSGeom *g1, *g2
* cdef char answer
- * g1 = self._geom # <<<<<<<<<<<<<<
+ * g1 = self._geom # <<<<<<<<<<<<<<
* g2 = geom._geom
* answer = GEOSWithin(g1, g2)
*/
__pyx_v_g1 = ((struct __pyx_obj_8_geoslib_BaseGeometry *)__pyx_v_self)->_geom;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":148
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":148
* cdef char answer
* g1 = self._geom
- * g2 = geom._geom # <<<<<<<<<<<<<<
+ * g2 = geom._geom # <<<<<<<<<<<<<<
* answer = GEOSWithin(g1, g2)
* if answer:
*/
__pyx_v_g2 = ((struct __pyx_obj_8_geoslib_BaseGeometry *)__pyx_v_geom)->_geom;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":149
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":149
* g1 = self._geom
* g2 = geom._geom
- * answer = GEOSWithin(g1, g2) # <<<<<<<<<<<<<<
+ * answer = GEOSWithin(g1, g2) # <<<<<<<<<<<<<<
* if answer:
* return True
*/
__pyx_v_answer = GEOSWithin(__pyx_v_g1, __pyx_v_g2);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":150
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":150
* g2 = geom._geom
* answer = GEOSWithin(g1, g2)
- * if answer: # <<<<<<<<<<<<<<
+ * if answer: # <<<<<<<<<<<<<<
* return True
* else:
*/
__pyx_1 = __pyx_v_answer;
if (__pyx_1) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":151
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":151
* answer = GEOSWithin(g1, g2)
* if answer:
- * return True # <<<<<<<<<<<<<<
+ * return True # <<<<<<<<<<<<<<
* else:
* return False
*/
@@ -811,10 +685,10 @@
}
/*else*/ {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":153
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":153
* return True
* else:
- * return False # <<<<<<<<<<<<<<
+ * return False # <<<<<<<<<<<<<<
*
* def simplify(self, tol):
*/
@@ -833,26 +707,24 @@
return __pyx_r;
}
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":155
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":155
* return False
*
- * def simplify(self, tol): # <<<<<<<<<<<<<<
+ * def simplify(self, tol): # <<<<<<<<<<<<<<
* cdef GEOSGeom *g1, *g3, *gout
* cdef double tolerance
*/
-static char __pyx_k_append[] = "append";
-static char __pyx_k_NotImplementedError[] = "NotImplementedError";
+static PyObject *__pyx_n_append;
+static PyObject *__pyx_n_NotImplementedError;
-static PyObject *__pyx_kp_append;
-static PyObject *__pyx_kp_NotImplementedError;
+static PyObject *__pyx_k_6p;
-static PyObject *__pyx_kp_4;
-
static PyObject *__pyx_builtin_NotImplementedError;
-static char __pyx_k_4[] = "intersections of type '%s' not yet implemented";
+static char __pyx_k_6[] = "intersections of type '%s' not yet implemented";
+#if GEOS_VERSION_MAJOR > 2
static PyObject *__pyx_pf_8_geoslib_12BaseGeometry_simplify(PyObject *__pyx_v_self, PyObject *__pyx_v_tol); /*proto*/
static PyObject *__pyx_pf_8_geoslib_12BaseGeometry_simplify(PyObject *__pyx_v_self, PyObject *__pyx_v_tol) {
GEOSGeom *__pyx_v_g1;
@@ -871,62 +743,63 @@
int __pyx_2;
PyObject *__pyx_3 = 0;
PyObject *__pyx_4 = 0;
+ PyObject *__pyx_5 = 0;
__pyx_v_b = Py_None; Py_INCREF(Py_None);
__pyx_v_p = Py_None; Py_INCREF(Py_None);
__pyx_v_pout = Py_None; Py_INCREF(Py_None);
__pyx_v_type = Py_None; Py_INCREF(Py_None);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":159
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":159
* cdef double tolerance
* cdef int numgeoms, i, typeid
- * tolerance = tol # <<<<<<<<<<<<<<
+ * tolerance = tol # <<<<<<<<<<<<<<
* g1 = self._geom
* g3 = GEOSSimplify(g1, tolerance)
*/
__pyx_1 = __pyx_PyFloat_AsDouble(__pyx_v_tol); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1;}
__pyx_v_tolerance = __pyx_1;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":160
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":160
* cdef int numgeoms, i, typeid
* tolerance = tol
- * g1 = self._geom # <<<<<<<<<<<<<<
+ * g1 = self._geom # <<<<<<<<<<<<<<
* g3 = GEOSSimplify(g1, tolerance)
* typeid = GEOSGeomTypeId(g3)
*/
__pyx_v_g1 = ((struct __pyx_obj_8_geoslib_BaseGeometry *)__pyx_v_self)->_geom;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":161
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":161
* tolerance = tol
* g1 = self._geom
- * g3 = GEOSSimplify(g1, tolerance) # <<<<<<<<<<<<<<
+ * g3 = GEOSSimplify(g1, tolerance) # <<<<<<<<<<<<<<
* typeid = GEOSGeomTypeId(g3)
* if typeid == GEOS_POLYGON:
*/
__pyx_v_g3 = GEOSSimplify(__pyx_v_g1, __pyx_v_tolerance);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":162
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":162
* g1 = self._geom
* g3 = GEOSSimplify(g1, tolerance)
- * typeid = GEOSGeomTypeId(g3) # <<<<<<<<<<<<<<
+ * typeid = GEOSGeomTypeId(g3) # <<<<<<<<<<<<<<
* if typeid == GEOS_POLYGON:
* b = _get_coords(g3)
*/
__pyx_v_typeid = GEOSGeomTypeId(__pyx_v_g3);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":163
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":163
* g3 = GEOSSimplify(g1, tolerance)
* typeid = GEOSGeomTypeId(g3)
- * if typeid == GEOS_POLYGON: # <<<<<<<<<<<<<<
+ * if typeid == GEOS_POLYGON: # <<<<<<<<<<<<<<
* b = _get_coords(g3)
* p = Polygon(b)
*/
__pyx_2 = (__pyx_v_typeid == GEOS_POLYGON);
if (__pyx_2) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":164
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":164
* typeid = GEOSGeomTypeId(g3)
* if typeid == GEOS_POLYGON:
- * b = _get_coords(g3) # <<<<<<<<<<<<<<
+ * b = _get_coords(g3) # <<<<<<<<<<<<<<
* p = Polygon(b)
* pout = [p]
*/
@@ -935,26 +808,26 @@
__pyx_v_b = __pyx_3;
__pyx_3 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":165
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":165
* if typeid == GEOS_POLYGON:
* b = _get_coords(g3)
- * p = Polygon(b) # <<<<<<<<<<<<<<
+ * p = Polygon(b) # <<<<<<<<<<<<<<
* pout = [p]
* elif typeid == GEOS_LINESTRING:
*/
__pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 165; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_INCREF(__pyx_v_b);
PyTuple_SET_ITEM(__pyx_3, 0, __pyx_v_b);
- __pyx_4 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_Polygon), ((PyObject *)__pyx_3), NULL); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 165; __pyx_clineno = __LINE__; goto __pyx_L1;}
- Py_DECREF(((PyObject *)__pyx_3)); __pyx_3 = 0;
+ __pyx_4 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_Polygon), __pyx_3, NULL); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 165; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
Py_DECREF(__pyx_v_p);
__pyx_v_p = __pyx_4;
__pyx_4 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":166
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":166
* b = _get_coords(g3)
* p = Polygon(b)
- * pout = [p] # <<<<<<<<<<<<<<
+ * pout = [p] # <<<<<<<<<<<<<<
* elif typeid == GEOS_LINESTRING:
* b = _get_coords(g3)
*/
@@ -962,25 +835,25 @@
Py_INCREF(__pyx_v_p);
PyList_SET_ITEM(__pyx_3, 0, __pyx_v_p);
Py_DECREF(__pyx_v_pout);
- __pyx_v_pout = ((PyObject *)__pyx_3);
+ __pyx_v_pout = __pyx_3;
__pyx_3 = 0;
goto __pyx_L4;
}
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":167
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":167
* p = Polygon(b)
* pout = [p]
- * elif typeid == GEOS_LINESTRING: # <<<<<<<<<<<<<<
+ * elif typeid == GEOS_LINESTRING: # <<<<<<<<<<<<<<
* b = _get_coords(g3)
* p = LineString(b)
*/
__pyx_2 = (__pyx_v_typeid == GEOS_LINESTRING);
if (__pyx_2) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":168
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":168
* pout = [p]
* elif typeid == GEOS_LINESTRING:
- * b = _get_coords(g3) # <<<<<<<<<<<<<<
+ * b = _get_coords(g3) # <<<<<<<<<<<<<<
* p = LineString(b)
* pout = [p]
*/
@@ -989,26 +862,26 @@
__pyx_v_b = __pyx_4;
__pyx_4 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":169
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":169
* elif typeid == GEOS_LINESTRING:
* b = _get_coords(g3)
- * p = LineString(b) # <<<<<<<<<<<<<<
+ * p = LineString(b) # <<<<<<<<<<<<<<
* pout = [p]
* elif typeid == GEOS_MULTIPOLYGON:
*/
__pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_INCREF(__pyx_v_b);
PyTuple_SET_ITEM(__pyx_3, 0, __pyx_v_b);
- __pyx_4 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_LineString), ((PyObject *)__pyx_3), NULL); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1;}
- Py_DECREF(((PyObject *)__pyx_3)); __pyx_3 = 0;
+ __pyx_4 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_LineString), __pyx_3, NULL); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
Py_DECREF(__pyx_v_p);
__pyx_v_p = __pyx_4;
__pyx_4 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":170
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":170
* b = _get_coords(g3)
* p = LineString(b)
- * pout = [p] # <<<<<<<<<<<<<<
+ * pout = [p] # <<<<<<<<<<<<<<
* elif typeid == GEOS_MULTIPOLYGON:
* numgeoms = GEOSGetNumGeometries(g3)
*/
@@ -1016,64 +889,64 @@
Py_INCREF(__pyx_v_p);
PyList_SET_ITEM(__pyx_3, 0, __pyx_v_p);
Py_DECREF(__pyx_v_pout);
- __pyx_v_pout = ((PyObject *)__pyx_3);
+ __pyx_v_pout = __pyx_3;
__pyx_3 = 0;
goto __pyx_L4;
}
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":171
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":171
* p = LineString(b)
* pout = [p]
- * elif typeid == GEOS_MULTIPOLYGON: # <<<<<<<<<<<<<<
+ * elif typeid == GEOS_MULTIPOLYGON: # <<<<<<<<<<<<<<
* numgeoms = GEOSGetNumGeometries(g3)
* pout = []
*/
__pyx_2 = (__pyx_v_typeid == GEOS_MULTIPOLYGON);
if (__pyx_2) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":172
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":172
* pout = [p]
* elif typeid == GEOS_MULTIPOLYGON:
- * numgeoms = GEOSGetNumGeometries(g3) # <<<<<<<<<<<<<<
+ * numgeoms = GEOSGetNumGeometries(g3) # <<<<<<<<<<<<<<
* pout = []
* for i from 0 <= i < numgeoms:
*/
__pyx_v_numgeoms = GEOSGetNumGeometries(__pyx_v_g3);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":173
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":173
* elif typeid == GEOS_MULTIPOLYGON:
* numgeoms = GEOSGetNumGeometries(g3)
- * pout = [] # <<<<<<<<<<<<<<
+ * pout = [] # <<<<<<<<<<<<<<
* for i from 0 <= i < numgeoms:
* gout = GEOSGetGeometryN(g3, i)
*/
__pyx_4 = PyList_New(0); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_v_pout);
- __pyx_v_pout = ((PyObject *)__pyx_4);
+ __pyx_v_pout = __pyx_4;
__pyx_4 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":174
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":174
* numgeoms = GEOSGetNumGeometries(g3)
* pout = []
- * for i from 0 <= i < numgeoms: # <<<<<<<<<<<<<<
+ * for i from 0 <= i < numgeoms: # <<<<<<<<<<<<<<
* gout = GEOSGetGeometryN(g3, i)
* b = _get_coords(gout)
*/
for (__pyx_v_i = 0; __pyx_v_i < __pyx_v_numgeoms; __pyx_v_i++) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":175
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":175
* pout = []
* for i from 0 <= i < numgeoms:
- * gout = GEOSGetGeometryN(g3, i) # <<<<<<<<<<<<<<
+ * gout = GEOSGetGeometryN(g3, i) # <<<<<<<<<<<<<<
* b = _get_coords(gout)
* p = Polygon(b)
*/
__pyx_v_gout = GEOSGetGeometryN(__pyx_v_g3, __pyx_v_i);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":176
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":176
* for i from 0 <= i < numgeoms:
* gout = GEOSGetGeometryN(g3, i)
- * b = _get_coords(gout) # <<<<<<<<<<<<<<
+ * b = _get_coords(gout) # <<<<<<<<<<<<<<
* p = Polygon(b)
* pout.append(p)
*/
@@ -1082,170 +955,182 @@
__pyx_v_b = __pyx_3;
__pyx_3 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":177
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":177
* gout = GEOSGetGeometryN(g3, i)
* b = _get_coords(gout)
- * p = Polygon(b) # <<<<<<<<<<<<<<
+ * p = Polygon(b) # <<<<<<<<<<<<<<
* pout.append(p)
* elif typeid == GEOS_MULTILINESTRING:
*/
__pyx_4 = PyTuple_New(1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 177; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_INCREF(__pyx_v_b);
PyTuple_SET_ITEM(__pyx_4, 0, __pyx_v_b);
- __pyx_3 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_Polygon), ((PyObject *)__pyx_4), NULL); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 177; __pyx_clineno = __LINE__; goto __pyx_L1;}
- Py_DECREF(((PyObject *)__pyx_4)); __pyx_4 = 0;
+ __pyx_3 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_Polygon), __pyx_4, NULL); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 177; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ Py_DECREF(__pyx_4); __pyx_4 = 0;
Py_DECREF(__pyx_v_p);
__pyx_v_p = __pyx_3;
__pyx_3 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":178
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":178
* b = _get_coords(gout)
* p = Polygon(b)
- * pout.append(p) # <<<<<<<<<<<<<<
+ * pout.append(p) # <<<<<<<<<<<<<<
* elif typeid == GEOS_MULTILINESTRING:
* numgeoms = GEOSGetNumGeometries(g3)
*/
- __pyx_4 = __Pyx_PyObject_Append(__pyx_v_pout, __pyx_v_p); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 178; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_4 = PyObject_GetAttr(__pyx_v_pout, __pyx_n_append); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 178; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 178; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ Py_INCREF(__pyx_v_p);
+ PyTuple_SET_ITEM(__pyx_3, 0, __pyx_v_p);
+ __pyx_5 = PyObject_Call(__pyx_4, __pyx_3, NULL); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 178; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_4); __pyx_4 = 0;
+ Py_DECREF(__pyx_3); __pyx_3 = 0;
+ Py_DECREF(__pyx_5); __pyx_5 = 0;
}
goto __pyx_L4;
}
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":179
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":179
* p = Polygon(b)
* pout.append(p)
- * elif typeid == GEOS_MULTILINESTRING: # <<<<<<<<<<<<<<
+ * elif typeid == GEOS_MULTILINESTRING: # <<<<<<<<<<<<<<
* numgeoms = GEOSGetNumGeometries(g3)
* pout = []
*/
__pyx_2 = (__pyx_v_typeid == GEOS_MULTILINESTRING);
if (__pyx_2) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":180
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":180
* pout.append(p)
* elif typeid == GEOS_MULTILINESTRING:
- * numgeoms = GEOSGetNumGeometries(g3) # <<<<<<<<<<<<<<
+ * numgeoms = GEOSGetNumGeometries(g3) # <<<<<<<<<<<<<<
* pout = []
* for i from 0 <= i < numgeoms:
*/
__pyx_v_numgeoms = GEOSGetNumGeometries(__pyx_v_g3);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":181
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":181
* elif typeid == GEOS_MULTILINESTRING:
* numgeoms = GEOSGetNumGeometries(g3)
- * pout = [] # <<<<<<<<<<<<<<
+ * pout = [] # <<<<<<<<<<<<<<
* for i from 0 <= i < numgeoms:
* gout = GEOSGetGeometryN(g3, i)
*/
- __pyx_3 = PyList_New(0); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 181; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_4 = PyList_New(0); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 181; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_v_pout);
- __pyx_v_pout = ((PyObject *)__pyx_3);
- __pyx_3 = 0;
+ __pyx_v_pout = __pyx_4;
+ __pyx_4 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":182
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":182
* numgeoms = GEOSGetNumGeometries(g3)
* pout = []
- * for i from 0 <= i < numgeoms: # <<<<<<<<<<<<<<
+ * for i from 0 <= i < numgeoms: # <<<<<<<<<<<<<<
* gout = GEOSGetGeometryN(g3, i)
* b = _get_coords(gout)
*/
for (__pyx_v_i = 0; __pyx_v_i < __pyx_v_numgeoms; __pyx_v_i++) {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":183
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":183
* pout = []
* for i from 0 <= i < numgeoms:
- * gout = GEOSGetGeometryN(g3, i) # <<<<<<<<<<<<<<
+ * gout = GEOSGetGeometryN(g3, i) # <<<<<<<<<<<<<<
* b = _get_coords(gout)
* p = LineString(b)
*/
__pyx_v_gout = GEOSGetGeometryN(__pyx_v_g3, __pyx_v_i);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":184
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":184
* for i from 0 <= i < numgeoms:
* gout = GEOSGetGeometryN(g3, i)
- * b = _get_coords(gout) # <<<<<<<<<<<<<<
+ * b = _get_coords(gout) # <<<<<<<<<<<<<<
* p = LineString(b)
* pout.append(p)
*/
- __pyx_4 = __pyx_f_8_geoslib__get_coords(__pyx_v_gout); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 184; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_3 = __pyx_f_8_geoslib__get_coords(__pyx_v_gout); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 184; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_v_b);
- __pyx_v_b = __pyx_4;
- __pyx_4 = 0;
+ __pyx_v_b = __pyx_3;
+ __pyx_3 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":185
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":185
* gout = GEOSGetGeometryN(g3, i)
* b = _get_coords(gout)
- * p = LineString(b) # <<<<<<<<<<<<<<
+ * p = LineString(b) # <<<<<<<<<<<<<<
* pout.append(p)
* else:
*/
- __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 185; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_5 = PyTuple_New(1); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 185; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_INCREF(__pyx_v_b);
- PyTuple_SET_ITEM(__pyx_3, 0, __pyx_v_b);
- __pyx_4 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_LineString), ((PyObject *)__pyx_3), NULL); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 185; __pyx_clineno = __LINE__; goto __pyx_L1;}
- Py_DECREF(((PyObject *)__pyx_3)); __pyx_3 = 0;
+ PyTuple_SET_ITEM(__pyx_5, 0, __pyx_v_b);
+ __pyx_4 = PyObject_Call(((PyObject*)__pyx_ptype_8_geoslib_LineString), __pyx_5, NULL); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 185; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ Py_DECREF(__pyx_5); __pyx_5 = 0;
Py_DECREF(__pyx_v_p);
__pyx_v_p = __pyx_4;
__pyx_4 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":186
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":186
* b = _get_coords(gout)
* p = LineString(b)
- * pout.append(p) # <<<<<<<<<<<<<<
+ * pout.append(p) # <<<<<<<<<<<<<<
* else:
* type = PyString_FromString(GEOSGeomType(g3))
*/
- __pyx_3 = __Pyx_PyObject_Append(__pyx_v_pout, __pyx_v_p); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 186; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_3 = PyObject_GetAttr(__pyx_v_pout, __pyx_n_append); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 186; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_5 = PyTuple_New(1); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 186; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ Py_INCREF(__pyx_v_p);
+ PyTuple_SET_ITEM(__pyx_5, 0, __pyx_v_p);
+ __pyx_4 = PyObject_Call(__pyx_3, __pyx_5, NULL); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 186; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_3); __pyx_3 = 0;
+ Py_DECREF(__pyx_5); __pyx_5 = 0;
+ Py_DECREF(__pyx_4); __pyx_4 = 0;
}
goto __pyx_L4;
}
/*else*/ {
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":188
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":188
* pout.append(p)
* else:
- * type = PyString_FromString(GEOSGeomType(g3)) # <<<<<<<<<<<<<<
+ * type = PyString_FromString(GEOSGeomType(g3)) # <<<<<<<<<<<<<<
* raise NotImplementedError("intersections of type '%s' not yet implemented" % (type))
* GEOSGeom_destroy(g3)
*/
- __pyx_4 = PyString_FromString(GEOSGeomType(__pyx_v_g3)); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 188; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_3 = PyString_FromString(GEOSGeomType(__pyx_v_g3)); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 188; __pyx_clineno = __LINE__; goto __pyx_L1;}
Py_DECREF(__pyx_v_type);
- __pyx_v_type = __pyx_4;
- __pyx_4 = 0;
+ __pyx_v_type = __pyx_3;
+ __pyx_3 = 0;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":189
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":189
* else:
* type = PyString_FromString(GEOSGeomType(g3))
- * raise NotImplementedError("intersections of type '%s' not yet implemented" % (type)) # <<<<<<<<<<<<<<
+ * raise NotImplementedError("intersections of type '%s' not yet implemented" % (type)) # <<<<<<<<<<<<<<
* GEOSGeom_destroy(g3)
* return pout
*/
- __pyx_3 = PyNumber_Remainder(__pyx_kp_4, __pyx_v_type); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ __pyx_5 = PyNumber_Remainder(__pyx_k_6p, __pyx_v_type); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1;}
__pyx_4 = PyTuple_New(1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1;}
- PyTuple_SET_ITEM(__pyx_4, 0, __pyx_3);
- __pyx_3 = 0;
- __pyx_3 = PyObject_Call(__pyx_builtin_NotImplementedError, ((PyObject *)__pyx_4), NULL); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1;}
- Py_DECREF(((PyObject *)__pyx_4)); __pyx_4 = 0;
+ PyTuple_SET_ITEM(__pyx_4, 0, __pyx_5);
+ __pyx_5 = 0;
+ __pyx_3 = PyObject_Call(__pyx_builtin_NotImplementedError, __pyx_4, NULL); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ Py_DECREF(__pyx_4); __pyx_4 = 0;
__Pyx_Raise(__pyx_3, 0, 0);
Py_DECREF(__pyx_3); __pyx_3 = 0;
{__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1;}
}
__pyx_L4:;
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":190
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":190
* type = PyString_FromString(GEOSGeomType(g3))
* raise NotImplementedError("intersections of type '%s' not yet implemented" % (type))
- * GEOSGeom_destroy(g3) # <<<<<<<<<<<<<<
+ * GEOSGeom_destroy(g3) # <<<<<<<<<<<<<<
* return pout
*
*/
GEOSGeom_destroy(__pyx_v_g3);
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":191
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":191
* raise NotImplementedError("intersections of type '%s' not yet implemented" % (type))
* GEOSGeom_destroy(g3)
- * return pout # <<<<<<<<<<<<<<
+ * return pout # <<<<<<<<<<<<<<
*
* def intersects(self, BaseGeometry geom):
*/
@@ -1258,6 +1143,7 @@
__pyx_L1:;
Py_XDECREF(__pyx_3);
Py_XDECREF(__pyx_4);
+ Py_XDECREF(__pyx_5);
__Pyx_AddTraceback("_geoslib.BaseGeometry.simplify");
__pyx_r = NULL;
__pyx_L0:;
@@ -1267,11 +1153,12 @@
Py_DECREF(__pyx_v_type);
return __pyx_r;
}
+#endif
-/* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":193
+/* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":193
* return pout
*
- * def intersects(self, BaseGeometry geom): # <<<<<<<<<<<<<<
+ * def intersects(self, BaseGeometry geom): # <<<<<<<<<<<<<<
* cdef GEOSGeom *g1, *g2
* cdef char answer
*/
@@ -1283,49 +1170,49 @@
char __pyx_v_answer;
PyObject *__pyx_r;
char __pyx_1;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_geom), __pyx_ptype_8_geoslib_BaseGeometry, 1, "geom", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 193; __pyx_clineno = __LINE__; goto __pyx_L1;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_geom), __pyx_ptype_8_geoslib_BaseGeometry, 1, "geom"))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 193; __pyx_clineno = __LINE__; goto __pyx_L1;}
- /* "/Volumes/User/jwhitaker/matplotlib/basemap/src/_geoslib.pyx":196
+ /* "/Users/jsw/python/matplotlib/trunk/toolkits/basemap/src/_geoslib.pyx":196
* cdef GEOSGeom *g1, *g2
* cdef char answer
- * g1 = self._geom # <<<<<<<<<<<<<<
+ * g1 = self._geom # <<<<<<<<<<<<<<
* g2 = geom._geom
* answer = GEOSIntersects(g1, g2)
*/
__pyx_v_g1 = ((struct __pyx_obj_8_geoslib_BaseGeometry *)__pyx_v_self)->_geom;
- /* "/Volumes/User/jwhitaker/matplotlib/...
[truncated message content] |