Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornulltoken <emeric.fermas@gmail.com>2012-07-04 18:24:09 +0400
committernulltoken <emeric.fermas@gmail.com>2012-07-07 14:16:09 +0400
commit98d6a1fdda5fa0605dee933930b5b7ddff4feb37 (patch)
treeadc78f510b1b14f359cf73fc8221a9ff6a5a1233 /src/util.h
parentcab65c2b23e1a01969c4586ef123ab153652aa6e (diff)
util: add git__isdigit()
Diffstat (limited to 'src/util.h')
-rw-r--r--src/util.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/util.h b/src/util.h
index adc665027..abdd543cc 100644
--- a/src/util.h
+++ b/src/util.h
@@ -204,6 +204,11 @@ GIT_INLINE(bool) git__isalpha(int c)
return ((c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z'));
}
+GIT_INLINE(bool) git__isdigit(int c)
+{
+ return (c >= '0' && c <= '9');
+}
+
GIT_INLINE(bool) git__isspace(int c)
{
return (c == ' ' || c == '\t' || c == '\n' || c == '\f' || c == '\r' || c == '\v');