瀏覽代碼

* extra IsDigit use

git-svn-id: trunk@39611 -
michael 7 年之前
父節點
當前提交
70aa822137
共有 1 個文件被更改,包括 2 次插入7 次删除
  1. 2 7
      packages/regexpr/src/regexpr.pas

+ 2 - 7
packages/regexpr/src/regexpr.pas

@@ -3719,13 +3719,8 @@ var
    if (p < TemplateEnd) and (p^ = '&')
     then inc (p) // this is '$&' or '${&}'
     else
-     while (p < TemplateEnd) and
-      {$IFDEF UniCode} //###0.935
-      (ord (p^) < 256) and (char (p^) in Digits)
-      {$ELSE}
-      (p^ in Digits)
-      {$ENDIF}
-       do begin
+     while (p < TemplateEnd) and IsDigit(p) do
+       begin
        Result := Result * 10 + (ord (p^) - ord ('0')); //###0.939
        inc (p);
       end;