From efb3f15da08c18674a332308b78573cba215845d Mon Sep 17 00:00:00 2001 From: George Rhoten Date: Wed, 18 Dec 2002 01:23:47 +0000 Subject: [PATCH] ICU-2135 Make more data const. X-SVN-Rev: 10712 --- icu4c/source/i18n/regexcst.h | 2 +- icu4c/source/i18n/regexcst.pl | 2 +- icu4c/source/i18n/repattrn.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/icu4c/source/i18n/regexcst.h b/icu4c/source/i18n/regexcst.h index 5637101ec34..a2cea8fd561 100644 --- a/icu4c/source/i18n/regexcst.h +++ b/icu4c/source/i18n/regexcst.h @@ -171,7 +171,7 @@ static const struct RegexTableEl gRuleParseStateTable[] = { , {doLiteralChar, 255, 12,0, TRUE} // 78 , {doExit, 255, 79,0, TRUE} // 79 errorDeath }; -static const char *RegexStateNames[] = { 0, +static const char * const RegexStateNames[] = { 0, "start", "term", 0, diff --git a/icu4c/source/i18n/regexcst.pl b/icu4c/source/i18n/regexcst.pl index 0daf06be7cf..16258e79a49 100755 --- a/icu4c/source/i18n/regexcst.pl +++ b/icu4c/source/i18n/regexcst.pl @@ -309,7 +309,7 @@ print " };\n"; # # This array is used for producing debugging output from the pattern parser. # -print "static const char *RegexStateNames[] = {"; +print "static const char * const RegexStateNames[] = {"; for ($state=0; $state<$num_states; $state++) { if ($stateNames[$state] ne "") { print " \"$stateNames[$state]\",\n"; diff --git a/icu4c/source/i18n/repattrn.cpp b/icu4c/source/i18n/repattrn.cpp index f19f4a599f9..4691d0b2844 100644 --- a/icu4c/source/i18n/repattrn.cpp +++ b/icu4c/source/i18n/repattrn.cpp @@ -422,7 +422,7 @@ int32_t RegexPattern::split(const UnicodeString &input, // Debugging function only. // //--------------------------------------------------------------------- -static const char *opNames[] = {URX_OPCODE_NAMES}; +static const char * const opNames[] = {URX_OPCODE_NAMES}; void RegexPattern::dumpOp(int32_t index) const { int32_t op = fCompiledPat->elementAti(index);