From 13769e4fff607279eb84271eaeb751dfed2d4505 Mon Sep 17 00:00:00 2001 From: John Maddock Date: Tue, 10 Jun 2003 11:59:44 +0000 Subject: [PATCH] Fixed array bounds so that gcc3 will actually compile the code, it's now seriously unmainable though, still it's the only thing that seems to work... [SVN r18761] --- include/boost/regex/v4/perl_matcher.hpp | 6 +++--- include/boost/regex/v4/perl_matcher_common.hpp | 4 ++-- include/boost/regex/v4/perl_matcher_non_recursive.hpp | 2 +- include/boost/regex/v4/regex.hpp | 1 - 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/include/boost/regex/v4/perl_matcher.hpp b/include/boost/regex/v4/perl_matcher.hpp index 703bc110..7d4ef764 100644 --- a/include/boost/regex/v4/perl_matcher.hpp +++ b/include/boost/regex/v4/perl_matcher.hpp @@ -377,9 +377,9 @@ private: repeater_count rep_obj; // table of functions to match states: - static const matcher_proc_type s_match_vtable[re_detail::syntax_element_count]; + static const matcher_proc_type s_match_vtable[27]; // table of functions to search for matching attempt start: - static const matcher_proc_type s_find_vtable[regbase::restart_count]; + static const matcher_proc_type s_find_vtable[7]; #ifdef BOOST_REGEX_NON_RECURSIVE @@ -424,7 +424,7 @@ private: // how many memory blocks have we used up?: unsigned used_block_count; // table of pointers to unwind proceedures: - static const unwind_proc_type s_unwind_table[re_detail::saved_state_count]; + static const unwind_proc_type s_unwind_table[14]; #endif // these operations aren't allowed, so are declared private: diff --git a/include/boost/regex/v4/perl_matcher_common.hpp b/include/boost/regex/v4/perl_matcher_common.hpp index 6a746a33..d339f907 100644 --- a/include/boost/regex/v4/perl_matcher_common.hpp +++ b/include/boost/regex/v4/perl_matcher_common.hpp @@ -768,7 +768,7 @@ bool perl_matcher::find_restart_lit template typename perl_matcher::matcher_proc_type const -perl_matcher::s_match_vtable[re_detail::syntax_element_count] = +perl_matcher::s_match_vtable[27] = { (&perl_matcher::match_startmark), &perl_matcher::match_endmark, @@ -811,7 +811,7 @@ perl_matcher::s_match_vtable[re_det template typename perl_matcher::matcher_proc_type const -perl_matcher::s_find_vtable[regbase::restart_count] = +perl_matcher::s_find_vtable[7] = { &perl_matcher::find_restart_any, &perl_matcher::find_restart_word, diff --git a/include/boost/regex/v4/perl_matcher_non_recursive.hpp b/include/boost/regex/v4/perl_matcher_non_recursive.hpp index f53d02cf..258212ac 100644 --- a/include/boost/regex/v4/perl_matcher_non_recursive.hpp +++ b/include/boost/regex/v4/perl_matcher_non_recursive.hpp @@ -1184,7 +1184,7 @@ bool perl_matcher::unwind_non_greed template typename perl_matcher::unwind_proc_type const -perl_matcher::s_unwind_table[re_detail::saved_state_count] = +perl_matcher::s_unwind_table[14] = { &perl_matcher::unwind_end, &perl_matcher::unwind_paren, diff --git a/include/boost/regex/v4/regex.hpp b/include/boost/regex/v4/regex.hpp index 34c3c4ea..c12c979b 100644 --- a/include/boost/regex/v4/regex.hpp +++ b/include/boost/regex/v4/regex.hpp @@ -60,7 +60,6 @@ #ifndef BOOST_REGEX_TRAITS_HPP #include #endif -#include #include #ifndef BOOST_REGEX_V4_CHAR_REGEX_TRAITS_HPP