diff options
author | Karl Williamson <public@khwilliamson.com> | 2013-02-13 17:21:18 -0700 |
---|---|---|
committer | Karl Williamson <public@khwilliamson.com> | 2013-07-03 19:21:19 -0600 |
commit | 05944450e0fc82eb8fc1fb5a4bf63f23785262a0 (patch) | |
tree | 5bf104b086cb4cc3a013103803d478288ca4b68e /inline_invlist.c | |
parent | 241136e0ed70738cccd6c4b20ce12b26231f30e5 (diff) | |
download | perl-05944450e0fc82eb8fc1fb5a4bf63f23785262a0.tar.gz |
regcomp.c: Move some #defines to only file that uses them
These were used in a header file to provide synchronization between
files. However, the only other file that would need them is a .pl file
which doesn't have access to them. So simplify things so that the
variables are either removed entirely if only used in a single place, or
are #defined in the area where they are used
Diffstat (limited to 'inline_invlist.c')
-rw-r--r-- | inline_invlist.c | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/inline_invlist.c b/inline_invlist.c index c6bc47ef38..ced42d85c0 100644 --- a/inline_invlist.c +++ b/inline_invlist.c @@ -8,30 +8,6 @@ #if defined(PERL_IN_UTF8_C) || defined(PERL_IN_REGCOMP_C) || defined(PERL_IN_REGEXEC_C) -#define INVLIST_LEN_OFFSET 0 /* Number of elements in the inversion list */ - -/* This is a combination of a version and data structure type, so that one - * being passed in can be validated to be an inversion list of the correct - * vintage. When the structure of the header is changed, a new random number - * in the range 2**31-1 should be generated. Then, if an auxiliary program - * doesn't change correspondingly, it will be discovered immediately */ -#define INVLIST_VERSION_ID_OFFSET 1 -#define INVLIST_VERSION_ID 1826693541 - -#define INVLIST_OFFSET_OFFSET 2 /* 0 or 1 */ -/* The UV at this position contains either 0 or 1. If 0, the inversion list - * contains the code point U+00000, and begins at element [0] in the array, - * which always contains 0. If 1, the inversion list doesn't contain U+0000, - * and it begins at element [1]. Inverting an inversion list consists of - * adding or removing the 0 at the beginning of it. By reserving a space for - * that 0, inversion can be made very fast: we just flip this UV */ - -/* For safety, when adding new elements, remember to #undef them at the end of - * the inversion list code section */ - -#define HEADER_LENGTH (INVLIST_OFFSET_OFFSET + 1) /* includes 1 for the constant - 0 element */ - /* An element is in an inversion list iff its index is even numbered: 0, 2, 4, * etc */ #define ELEMENT_RANGE_MATCHES_INVLIST(i) (! ((i) & 1)) |