diff options
| author | herbelin | 2006-06-10 17:22:33 +0000 |
|---|---|---|
| committer | herbelin | 2006-06-10 17:22:33 +0000 |
| commit | 16e7a5e75bae56b4d4ed4a2465d0c6f43348a380 (patch) | |
| tree | 533c2fbb80884b3b206179195c3eeec5df2fb577 | |
| parent | f53213fdf0ae38a1495a56c02ec734454691b493 (diff) | |
Bug is_number
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@8947 85f007b7-540e-0410-9357-904b9bb8a0f7
| -rw-r--r-- | parsing/lexer.ml4 | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/parsing/lexer.ml4 b/parsing/lexer.ml4 index c8756a49fb..8be0b540a0 100644 --- a/parsing/lexer.ml4 +++ b/parsing/lexer.ml4 @@ -589,9 +589,10 @@ let is_ident_not_keyword s = | _ -> false let is_number s = - match s.[0] with - | '0'..'9' -> true - | _ -> false + let rec aux i = + String.length s = i or + match s.[i] with '0'..'9' -> aux (i+1) | _ -> false + in aux 0 let strip s = let len = |
