diff options
| author | Calvin Buckley <calvin@cmpct.info> | 2021-07-06 23:25:13 -0300 |
|---|---|---|
| committer | Calvin Buckley <calvin@cmpct.info> | 2021-07-06 23:28:47 -0300 |
| commit | c1aca3fedaf2cfe6d9bc7f5dbf5828a872dd74e5 (patch) | |
| tree | e65ff448b3a2391b3e63b7cb6a13cd2a70fcf4a5 /src/integer.h | |
| parent | 6c78fd06e3cedec818122ecc7f90e6c81e497354 (diff) | |
| download | libgit2-c1aca3fedaf2cfe6d9bc7f5dbf5828a872dd74e5.tar.gz | |
Initial pass at using int64_t instead of long long
Even on systems without C99 where long long and stdint are both
missing, we can shim stdint and point it to any compiler-specific
type (i.e long long, _int64, etc.).
Also next is constant suffixes and determining what needs to
include stdint.
Diffstat (limited to 'src/integer.h')
| -rw-r--r-- | src/integer.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/integer.h b/src/integer.h index a3a0f53ee..63277177b 100644 --- a/src/integer.h +++ b/src/integer.h @@ -43,10 +43,10 @@ GIT_INLINE(int) git__is_ulong(int64_t p) } /** @return true if p fits into the range of an int */ -GIT_INLINE(int) git__is_int(long long p) +GIT_INLINE(int) git__is_int(int64_t p) { int r = (int)p; - return p == (long long)r; + return p == (int64_t)r; } /* Use clang/gcc compiler intrinsics whenever possible */ |
