From 4a85d662012360fecffc9b0e58a582204f631957 Mon Sep 17 00:00:00 2001 From: "Claudius \"keldu\" Holeksa" Date: Tue, 17 Jun 2025 14:41:12 +0200 Subject: Rewriting parts to avoid infinite recursion in flat index call --- modules/codec/tests/SConscript | 2 ++ modules/codec/tests/codec.cpp | 3 +++ modules/codec/tests/data_raw.cpp | 1 + 3 files changed, 6 insertions(+) (limited to 'modules/codec/tests') diff --git a/modules/codec/tests/SConscript b/modules/codec/tests/SConscript index f8ffc92..ebaf45f 100644 --- a/modules/codec/tests/SConscript +++ b/modules/codec/tests/SConscript @@ -13,6 +13,8 @@ dir_path = Dir('.').abspath test_cases_env = env.Clone(); test_cases_env.Append(LIBS=['forstio-test']); +# test_cases_env.Append(CCFLAGS=['-fsanitize=address','-g']); +# test_cases_env.Append(LINKFLAGS=['-fsanitize=address']); test_cases_env.sources = sorted(glob.glob(dir_path + "/*.cpp")) test_cases_env.headers = sorted(glob.glob(dir_path + "/*.hpp")) diff --git a/modules/codec/tests/codec.cpp b/modules/codec/tests/codec.cpp index ef45b4e..27bc454 100644 --- a/modules/codec/tests/codec.cpp +++ b/modules/codec/tests/codec.cpp @@ -53,11 +53,14 @@ using TestInterface = Interface< } SAW_TEST("One Dimensional Array") { using namespace saw; + std::cout<<"foo "< arr{{{500u}}}; + std::cout<<"foo2 "< i = 0; i < arr.size(); ++i){ arr.at(i).set(bar++); } diff --git a/modules/codec/tests/data_raw.cpp b/modules/codec/tests/data_raw.cpp index 26c2721..930758d 100644 --- a/modules/codec/tests/data_raw.cpp +++ b/modules/codec/tests/data_raw.cpp @@ -23,6 +23,7 @@ SAW_TEST("Data NativeRaw/Array of Primitives"){ a.set(5); b.set(6); + d.set(23); // Check if it's a reference being manipulated SAW_EXPECT(a.get() == 5, "'a' has unexpected value."); -- cgit v1.2.3