summaryrefslogtreecommitdiff
path: root/test cases/unit
diff options
context:
space:
mode:
authorMichael Hirsch, Ph.D <10931741+scivision@users.noreply.github.com>2019-11-18 15:21:37 -0500
committerJussi Pakkanen <jpakkane@gmail.com>2019-11-18 22:21:36 +0200
commit83b4e981c4dd8b8ea521a6150a34636d10a67211 (patch)
tree3ac84e307e6a2589073a7542a0d7127738f09576 /test cases/unit
parent0435691e83fb7172e2a9635d2eb32d5521089916 (diff)
downloadmeson-83b4e981c4dd8b8ea521a6150a34636d10a67211.tar.gz
Use strict function prototypes
Diffstat (limited to 'test cases/unit')
-rw-r--r--test cases/unit/14 testsetup selection/main.c2
-rw-r--r--test cases/unit/14 testsetup selection/subprojects/bar/bar.c2
-rw-r--r--test cases/unit/14 testsetup selection/subprojects/foo/foo.c2
-rw-r--r--test cases/unit/25 non-permitted kwargs/meson.build2
-rw-r--r--test cases/unit/29 guessed linker dependencies/exe/app.c2
-rw-r--r--test cases/unit/32 pkgconfig use libraries/app/app.c2
-rw-r--r--test cases/unit/4 suite selection/failing_test.c2
-rw-r--r--test cases/unit/4 suite selection/subprojects/subprjfail/failing_test.c2
-rw-r--r--test cases/unit/4 suite selection/subprojects/subprjmix/failing_test.c2
-rw-r--r--test cases/unit/4 suite selection/subprojects/subprjmix/successful_test.c2
-rw-r--r--test cases/unit/4 suite selection/subprojects/subprjsucc/successful_test.c2
-rw-r--r--test cases/unit/4 suite selection/successful_test.c2
-rw-r--r--test cases/unit/45 vscpp17/main.cpp4
-rw-r--r--test cases/unit/57 introspection/t1.cpp2
-rw-r--r--test cases/unit/57 introspection/t2.cpp2
-rw-r--r--test cases/unit/57 introspection/t3.cpp2
-rw-r--r--test cases/unit/59 introspect buildoptions/main.c2
-rw-r--r--test cases/unit/68 static archive stripping/app/appA.c2
-rw-r--r--test cases/unit/68 static archive stripping/app/appB.c2
19 files changed, 20 insertions, 20 deletions
diff --git a/test cases/unit/14 testsetup selection/main.c b/test cases/unit/14 testsetup selection/main.c
index 33c14ce1d..9b6bdc2ec 100644
--- a/test cases/unit/14 testsetup selection/main.c
+++ b/test cases/unit/14 testsetup selection/main.c
@@ -1,3 +1,3 @@
-int main() {
+int main(void) {
return 0;
}
diff --git a/test cases/unit/14 testsetup selection/subprojects/bar/bar.c b/test cases/unit/14 testsetup selection/subprojects/bar/bar.c
index 33c14ce1d..9b6bdc2ec 100644
--- a/test cases/unit/14 testsetup selection/subprojects/bar/bar.c
+++ b/test cases/unit/14 testsetup selection/subprojects/bar/bar.c
@@ -1,3 +1,3 @@
-int main() {
+int main(void) {
return 0;
}
diff --git a/test cases/unit/14 testsetup selection/subprojects/foo/foo.c b/test cases/unit/14 testsetup selection/subprojects/foo/foo.c
index 33c14ce1d..9b6bdc2ec 100644
--- a/test cases/unit/14 testsetup selection/subprojects/foo/foo.c
+++ b/test cases/unit/14 testsetup selection/subprojects/foo/foo.c
@@ -1,3 +1,3 @@
-int main() {
+int main(void) {
return 0;
}
diff --git a/test cases/unit/25 non-permitted kwargs/meson.build b/test cases/unit/25 non-permitted kwargs/meson.build
index 9f7dc1f76..287acfd87 100644
--- a/test cases/unit/25 non-permitted kwargs/meson.build
+++ b/test cases/unit/25 non-permitted kwargs/meson.build
@@ -1,5 +1,5 @@
project('non-permitted kwargs', 'c')
cc = meson.get_compiler('c')
cc.has_header_symbol('stdio.h', 'printf', prefixxx: '#define XXX')
-cc.links('int main(){}', argsxx: '')
+cc.links('int main(void){}', argsxx: '')
cc.get_id(invalidxx: '')
diff --git a/test cases/unit/29 guessed linker dependencies/exe/app.c b/test cases/unit/29 guessed linker dependencies/exe/app.c
index 1031a4204..29c8d9c9a 100644
--- a/test cases/unit/29 guessed linker dependencies/exe/app.c
+++ b/test cases/unit/29 guessed linker dependencies/exe/app.c
@@ -1,6 +1,6 @@
void liba_func();
-int main() {
+int main(void) {
liba_func();
return 0;
}
diff --git a/test cases/unit/32 pkgconfig use libraries/app/app.c b/test cases/unit/32 pkgconfig use libraries/app/app.c
index b271a9e61..7b8d8fa13 100644
--- a/test cases/unit/32 pkgconfig use libraries/app/app.c
+++ b/test cases/unit/32 pkgconfig use libraries/app/app.c
@@ -1,6 +1,6 @@
void libb_func();
-int main() {
+int main(void) {
libb_func();
return 0;
}
diff --git a/test cases/unit/4 suite selection/failing_test.c b/test cases/unit/4 suite selection/failing_test.c
index bf0090735..393344d05 100644
--- a/test cases/unit/4 suite selection/failing_test.c
+++ b/test cases/unit/4 suite selection/failing_test.c
@@ -1 +1 @@
-int main() { return -1 ; }
+int main(void) { return -1 ; }
diff --git a/test cases/unit/4 suite selection/subprojects/subprjfail/failing_test.c b/test cases/unit/4 suite selection/subprojects/subprjfail/failing_test.c
index bf0090735..393344d05 100644
--- a/test cases/unit/4 suite selection/subprojects/subprjfail/failing_test.c
+++ b/test cases/unit/4 suite selection/subprojects/subprjfail/failing_test.c
@@ -1 +1 @@
-int main() { return -1 ; }
+int main(void) { return -1 ; }
diff --git a/test cases/unit/4 suite selection/subprojects/subprjmix/failing_test.c b/test cases/unit/4 suite selection/subprojects/subprjmix/failing_test.c
index bf0090735..393344d05 100644
--- a/test cases/unit/4 suite selection/subprojects/subprjmix/failing_test.c
+++ b/test cases/unit/4 suite selection/subprojects/subprjmix/failing_test.c
@@ -1 +1 @@
-int main() { return -1 ; }
+int main(void) { return -1 ; }
diff --git a/test cases/unit/4 suite selection/subprojects/subprjmix/successful_test.c b/test cases/unit/4 suite selection/subprojects/subprjmix/successful_test.c
index 29c0525a5..8842fc122 100644
--- a/test cases/unit/4 suite selection/subprojects/subprjmix/successful_test.c
+++ b/test cases/unit/4 suite selection/subprojects/subprjmix/successful_test.c
@@ -1 +1 @@
-int main() { return 0 ; }
+int main(void) { return 0 ; }
diff --git a/test cases/unit/4 suite selection/subprojects/subprjsucc/successful_test.c b/test cases/unit/4 suite selection/subprojects/subprjsucc/successful_test.c
index 29c0525a5..8842fc122 100644
--- a/test cases/unit/4 suite selection/subprojects/subprjsucc/successful_test.c
+++ b/test cases/unit/4 suite selection/subprojects/subprjsucc/successful_test.c
@@ -1 +1 @@
-int main() { return 0 ; }
+int main(void) { return 0 ; }
diff --git a/test cases/unit/4 suite selection/successful_test.c b/test cases/unit/4 suite selection/successful_test.c
index 29c0525a5..8842fc122 100644
--- a/test cases/unit/4 suite selection/successful_test.c
+++ b/test cases/unit/4 suite selection/successful_test.c
@@ -1 +1 @@
-int main() { return 0 ; }
+int main(void) { return 0 ; }
diff --git a/test cases/unit/45 vscpp17/main.cpp b/test cases/unit/45 vscpp17/main.cpp
index 36e4156e4..bfe247055 100644
--- a/test cases/unit/45 vscpp17/main.cpp
+++ b/test cases/unit/45 vscpp17/main.cpp
@@ -1,7 +1,7 @@
-[[nodiscard]] int foo() {
+[[nodiscard]] int foo(void) {
return 0;
}
-int main() {
+int main(void) {
return foo();
}
diff --git a/test cases/unit/57 introspection/t1.cpp b/test cases/unit/57 introspection/t1.cpp
index 2bcaab87c..901e3f1ac 100644
--- a/test cases/unit/57 introspection/t1.cpp
+++ b/test cases/unit/57 introspection/t1.cpp
@@ -1,6 +1,6 @@
#include "sharedlib/shared.hpp"
-int main() {
+int main(void) {
SharedClass cl1;
if(cl1.getNumber() != 42) {
return 1;
diff --git a/test cases/unit/57 introspection/t2.cpp b/test cases/unit/57 introspection/t2.cpp
index fee5097c3..8323f4681 100644
--- a/test cases/unit/57 introspection/t2.cpp
+++ b/test cases/unit/57 introspection/t2.cpp
@@ -1,6 +1,6 @@
#include "staticlib/static.h"
-int main() {
+int main(void) {
if(add_numbers(1, 2) != 3) {
return 1;
}
diff --git a/test cases/unit/57 introspection/t3.cpp b/test cases/unit/57 introspection/t3.cpp
index 8a906e079..dd518e809 100644
--- a/test cases/unit/57 introspection/t3.cpp
+++ b/test cases/unit/57 introspection/t3.cpp
@@ -1,7 +1,7 @@
#include "sharedlib/shared.hpp"
#include "staticlib/static.h"
-int main() {
+int main(void) {
for(int i = 0; i < 1000; add_numbers(i, 1)) {
SharedClass cl1;
if(cl1.getNumber() != 42) {
diff --git a/test cases/unit/59 introspect buildoptions/main.c b/test cases/unit/59 introspect buildoptions/main.c
index ef99ae617..709730f19 100644
--- a/test cases/unit/59 introspect buildoptions/main.c
+++ b/test cases/unit/59 introspect buildoptions/main.c
@@ -1,6 +1,6 @@
#include <stdio.h>
-int main() {
+int main(void) {
printf("Hello World");
return 0;
}
diff --git a/test cases/unit/68 static archive stripping/app/appA.c b/test cases/unit/68 static archive stripping/app/appA.c
index 9c14a0267..e44b54a92 100644
--- a/test cases/unit/68 static archive stripping/app/appA.c
+++ b/test cases/unit/68 static archive stripping/app/appA.c
@@ -1,4 +1,4 @@
#include <stdio.h>
#include <libA.h>
-int main() { printf("The answer is: %d\n", libA_func()); }
+int main(void) { printf("The answer is: %d\n", libA_func()); }
diff --git a/test cases/unit/68 static archive stripping/app/appB.c b/test cases/unit/68 static archive stripping/app/appB.c
index 05b4a2ab0..0ec0b629e 100644
--- a/test cases/unit/68 static archive stripping/app/appB.c
+++ b/test cases/unit/68 static archive stripping/app/appB.c
@@ -1,4 +1,4 @@
#include <stdio.h>
#include <libB.h>
-int main() { printf("The answer is: %d\n", libB_func()); }
+int main(void) { printf("The answer is: %d\n", libB_func()); }