From 9b2d58ca944f3216ea669aba39a8bf6e8dfd1eb8 Mon Sep 17 00:00:00 2001 From: Thomas Lange Date: Tue, 12 Dec 2000 15:13:07 +0000 Subject: #81811# IsDigit new --- starmath/source/parse.cxx | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'starmath') diff --git a/starmath/source/parse.cxx b/starmath/source/parse.cxx index f10d685d864f..e49bfe6666fd 100644 --- a/starmath/source/parse.cxx +++ b/starmath/source/parse.cxx @@ -2,9 +2,9 @@ * * $RCSfile: parse.cxx,v $ * - * $Revision: 1.1.1.1 $ + * $Revision: 1.2 $ * - * last change: $Author: hr $ $Date: 2000-09-18 16:57:26 $ + * last change: $Author: tl $ $Date: 2000-12-12 16:13:07 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -102,6 +102,11 @@ static const xub_Unicode aDelimiterTable[] = }; +static inline BOOL IsDigit( sal_Unicode cChar ) +{ + return '0' <= cChar && cChar <= '9'; +} + /////////////////////////////////////////////////////////////////////////// SmToken::SmToken() : @@ -619,7 +624,7 @@ void SmParser::NextToken() } USHORT i; - for (i = 0; (i < n) && (isdigit(*pBuffer) || + for (i = 0; (i < n) && (IsDigit(*pBuffer) || (*pBuffer == '.') || (*pBuffer == ',')); i++) pBuffer ++; -- cgit v1.2.3