From 2edb18e9b789cdb0c6b7e8b9ded16e7f57f777b4 Mon Sep 17 00:00:00 2001 From: George Rhoten Date: Fri, 17 Aug 2001 03:08:36 +0000 Subject: [PATCH] ICU-329 The private function stoi() no longer needs a UErrorCode X-SVN-Rev: 5508 --- icu4c/source/i18n/msgfmt.cpp | 5 ++--- icu4c/source/i18n/unicode/msgfmt.h | 3 +-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/icu4c/source/i18n/msgfmt.cpp b/icu4c/source/i18n/msgfmt.cpp index 0253197f6d9..b6d943399d8 100644 --- a/icu4c/source/i18n/msgfmt.cpp +++ b/icu4c/source/i18n/msgfmt.cpp @@ -1069,8 +1069,7 @@ MessageFormat::releaseNumberFormat(NumberFormat *adopt) * a call to wtoi(). */ int32_t -MessageFormat::stoi(const UnicodeString& string, - UErrorCode& status) +MessageFormat::stoi(const UnicodeString& string) { /* NumberFormat *myFormat = getNumberFormat(status); @@ -1156,7 +1155,7 @@ MessageFormat::makeFormat(/*int32_t position, */ // get the number int32_t argumentNumber; int32_t oldMaxOffset = fMaxOffset; - argumentNumber = stoi(segments[1], success); // always unlocalized! + argumentNumber = stoi(segments[1]); // always unlocalized! if (argumentNumber < 0 || argumentNumber > 9) { success = U_INVALID_FORMAT_ERROR; return; diff --git a/icu4c/source/i18n/unicode/msgfmt.h b/icu4c/source/i18n/unicode/msgfmt.h index 6b0de96714f..3e10b8da072 100644 --- a/icu4c/source/i18n/unicode/msgfmt.h +++ b/icu4c/source/i18n/unicode/msgfmt.h @@ -606,10 +606,9 @@ private: * which is static (shared by all MessageFormat instances). This replaces * a call to wtoi(). * @param string the source string to convert with - * @param status the error code. * @return the converted number. */ - static int32_t stoi(const UnicodeString& string, UErrorCode& status); + static int32_t stoi(const UnicodeString& string); /** * Converts an integer value to a string using a default NumberFormat object