diff options
author | Arnaud Versini <arnaud.versini@gmail.com> | 2015-01-25 13:58:08 +0100 |
---|---|---|
committer | Arnaud Versini <arnaud.versini@libreoffice.org> | 2015-01-31 09:48:27 +0000 |
commit | 4b9a9ce8a0e5e0716dad9a9ec87d16237e534dc2 (patch) | |
tree | 8b72a0f8e4b93724cb0dfba51e74353946ff4eb7 /basic/source/comp/basiccharclass.cxx | |
parent | dec950dc4761c1c2f0cf27b20d70f5a0db44d602 (diff) |
Use rtl/character.hxx in basic module when possible
Change-Id: I1296541ac1a6a65a613818a1264c2b7482915e64
Reviewed-on: https://gerrit.libreoffice.org/14170
Reviewed-by: Arnaud Versini <arnaud.versini@libreoffice.org>
Tested-by: Arnaud Versini <arnaud.versini@libreoffice.org>
Diffstat (limited to 'basic/source/comp/basiccharclass.cxx')
-rw-r--r-- | basic/source/comp/basiccharclass.cxx | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/basic/source/comp/basiccharclass.cxx b/basic/source/comp/basiccharclass.cxx index 59ae7242c226..8e404cc42c7f 100644 --- a/basic/source/comp/basiccharclass.cxx +++ b/basic/source/comp/basiccharclass.cxx @@ -108,18 +108,13 @@ bool BasicCharClass::isLetterUnicode( sal_Unicode c ) bool BasicCharClass::isAlpha( sal_Unicode c, bool bCompatible ) { - return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') + return rtl::isAsciiAlpha(c) || (bCompatible && isLetter( c )); } -bool BasicCharClass::isDigit( sal_Unicode c ) -{ - return (c >= '0' && c <= '9'); -} - bool BasicCharClass::isAlphaNumeric( sal_Unicode c, bool bCompatible ) { - return isDigit( c ) || isAlpha( c, bCompatible ); + return rtl::isAsciiDigit( c ) || isAlpha( c, bCompatible ); } bool BasicCharClass::isWhitespace( sal_Unicode c ) |