diff options
| author | Fangrui Song <[email protected]> | 2022-04-09 09:57:40 -0700 |
|---|---|---|
| committer | Jack O'Connor <[email protected]> | 2022-04-09 11:00:17 -0700 |
| commit | 9114ff8ed1818f1d9831f1b8963a469b2f9e9438 (patch) | |
| tree | cc2c0708264254045e49e9071bac44412946e5b8 | |
| parent | 4393a9b79c4d39c6836010a8b5f1a04d069e4521 (diff) | |
add prototypes to fix -Wstrict-prototypes warnings
| -rw-r--r-- | c/README.md | 2 | ||||
| -rw-r--r-- | c/blake3_dispatch.c | 4 | ||||
| -rw-r--r-- | c/example.c | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/c/README.md b/c/README.md index 6807bee..ad8e5fb 100644 --- a/c/README.md +++ b/c/README.md @@ -13,7 +13,7 @@ result: #include <string.h> #include <unistd.h> -int main() { +int main(void) { // Initialize the hasher. blake3_hasher hasher; blake3_hasher_init(&hasher); diff --git a/c/blake3_dispatch.c b/c/blake3_dispatch.c index b498058..95213db 100644 --- a/c/blake3_dispatch.c +++ b/c/blake3_dispatch.c @@ -17,7 +17,7 @@ #define MAYBE_UNUSED(x) (void)((x)) #if defined(IS_X86) -static uint64_t xgetbv() { +static uint64_t xgetbv(void) { #if defined(_MSC_VER) return _xgetbv(0); #else @@ -82,7 +82,7 @@ static /* Allow the variable to be controlled manually for testing */ static #endif enum cpu_feature - get_cpu_features() { + get_cpu_features(void) { if (g_cpu_features != UNDEFINED) { return g_cpu_features; diff --git a/c/example.c b/c/example.c index 0537548..ee8430b 100644 --- a/c/example.c +++ b/c/example.c @@ -5,7 +5,7 @@ #include <string.h> #include <unistd.h> -int main() { +int main(void) { // Initialize the hasher. blake3_hasher hasher; blake3_hasher_init(&hasher); |
