source: trunk/essentials/dev-lang/python/Modules/sre.h

Last change on this file was 3225, checked in by bird, 19 years ago

Python 2.5

File size: 2.6 KB
Line 
1/*
2 * Secret Labs' Regular Expression Engine
3 *
4 * regular expression matching engine
5 *
6 * Copyright (c) 1997-2001 by Secret Labs AB. All rights reserved.
7 *
8 * See the _sre.c file for information on usage and redistribution.
9 */
10
11#ifndef SRE_INCLUDED
12#define SRE_INCLUDED
13
14#include "sre_constants.h"
15
16/* size of a code word (must be unsigned short or larger, and
17 large enough to hold a Py_UNICODE character) */
18#ifdef Py_UNICODE_WIDE
19#define SRE_CODE Py_UCS4
20#else
21#define SRE_CODE unsigned short
22#endif
23
24typedef struct {
25 PyObject_VAR_HEAD
26 Py_ssize_t groups; /* must be first! */
27 PyObject* groupindex;