summaryrefslogtreecommitdiff
path: root/tests/projects
diff options
context:
space:
mode:
authorSaikari <[email protected]>2026-04-03 12:05:55 +0300
committerSaikari <[email protected]>2026-04-03 12:05:55 +0300
commit03761ed3cde38efa84bd7f170415ad83bf9d2787 (patch)
tree2e970d7f32b23a051d355f9ba271d3d5f7ed17ed /tests/projects
parent74dbb8e44c4258c491a362dcd4b0583ba1806fd5 (diff)
refactor safety test and toolchain configuration for filc: streamline function pointer test and enhance toolset definitions
Diffstat (limited to 'tests/projects')
-rw-r--r--tests/projects/c/filc/safety_test/src/main.c6
-rw-r--r--tests/projects/c/filc/safety_test/xmake.lua2
2 files changed, 3 insertions, 5 deletions
diff --git a/tests/projects/c/filc/safety_test/src/main.c b/tests/projects/c/filc/safety_test/src/main.c
index 4f5ad91b9..d23718c3e 100644
--- a/tests/projects/c/filc/safety_test/src/main.c
+++ b/tests/projects/c/filc/safety_test/src/main.c
@@ -7,12 +7,10 @@
#include <stdfil.h>
#include <stdlib.h>
-static void foo(void)
-{
+static void foo(void) {
}
-int main()
-{
+int main() {
void (*my_foo)(void) = (void(*)(void))((char*)foo + 42);
my_foo();
return 0;
diff --git a/tests/projects/c/filc/safety_test/xmake.lua b/tests/projects/c/filc/safety_test/xmake.lua
index e2d47da57..4ebbf9792 100644
--- a/tests/projects/c/filc/safety_test/xmake.lua
+++ b/tests/projects/c/filc/safety_test/xmake.lua
@@ -4,6 +4,6 @@ add_requires("filc")
target("safety_test")
set_kind("binary")
- set_toolchains("filc", {packages = "filc"})
+ set_toolchains("@filc")
add_packages("filc")
add_files("src/*.c")