summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorMitya Selivanov <0x7fffff@guattari.ru>2022-08-21 15:56:39 +0400
committerMitya Selivanov <0x7fffff@guattari.ru>2022-08-21 15:56:39 +0400
commit54cc273a0a4421b25b40eb25449de5d3a601534b (patch)
tree696ad2857e16d722722604ea62a2ef321a57e692 /source
parent7c8cb967045386f231055f5a3fb545af17dd9b55 (diff)
downloadkit-54cc273a0a4421b25b40eb25449de5d3a601534b.zip
Remove noexcept
Diffstat (limited to 'source')
-rw-r--r--source/kit_test/test.h4
-rw-r--r--source/test/unittests/thread.test.c6
2 files changed, 7 insertions, 3 deletions
diff --git a/source/kit_test/test.h b/source/kit_test/test.h
index 2ef339f..afc1009 100644
--- a/source/kit_test/test.h
+++ b/source/kit_test/test.h
@@ -45,10 +45,10 @@ extern kit_tests_list_t kit_tests_list;
#ifdef __cplusplus
# define KIT_TEST_ON_START_(f) \
- static void f(void) noexcept; \
+ static void f(void); \
static int KIT_TEST_CONCAT3_(_kit_test_init_, __LINE__, \
f) = (f(), 0); \
- static void f(void) noexcept
+ static void f(void)
#else
# ifdef _MSC_VER
# ifdef __cplusplus
diff --git a/source/test/unittests/thread.test.c b/source/test/unittests/thread.test.c
index a797fee..786e992 100644
--- a/source/test/unittests/thread.test.c
+++ b/source/test/unittests/thread.test.c
@@ -3,7 +3,9 @@
#define KIT_TEST_FILE thread
#include "../../kit_test/test.h"
-static int test_nothing(void *_) { }
+static int test_nothing(void *_) {
+ return 0;
+}
static int test_run(void *data) {
int *n = (int *) data;
@@ -21,11 +23,13 @@ static int test_exit(void *data) {
static int test_yield(void *data) {
thrd_yield();
+ return 0;
}
static int test_sleep(void *data) {
struct timespec t = { .tv_sec = 0, .tv_nsec = 10000000 };
thrd_sleep(&t, NULL);
+ return 0;
}
TEST("thread run") {