diff options
| author | Bent Bisballe Nyeng <deva@aasimon.org> | 2026-02-02 18:30:58 +0100 |
|---|---|---|
| committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2026-02-02 18:57:44 +0100 |
| commit | 6accb227b75fef7e99257b0078eb95f9aa0823cc (patch) | |
| tree | 41ed3773d1f8b05eea0e6ff86010237f6e4bd25a /test/suite | |
| parent | 19d1dd34fbc87b6637147785332f180e36acdfef (diff) | |
New syntax
Diffstat (limited to 'test/suite')
| -rw-r--r-- | test/suite/ctor_files/ctor.cc.bar | 10 | ||||
| -rw-r--r-- | test/suite/ctor_files/ctor.cc.base | 10 | ||||
| -rw-r--r-- | test/suite/ctor_files/ctor.cc.generated | 32 | ||||
| -rw-r--r-- | test/suite/ctor_files/ctor.cc.generated2 | 28 | ||||
| -rw-r--r-- | test/suite/ctor_files/ctor.cc.multi | 10 |
5 files changed, 45 insertions, 45 deletions
diff --git a/test/suite/ctor_files/ctor.cc.bar b/test/suite/ctor_files/ctor.cc.bar index ab88379..9a45878 100644 --- a/test/suite/ctor_files/ctor.cc.bar +++ b/test/suite/ctor_files/ctor.cc.bar @@ -11,12 +11,12 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) return { { - .name = "hello", - .target = "hello", - .sources = { + ctor::name("hello"), + ctor::target("hello"), + ctor::sources{ "hello.cc", }, - .flags = { + ctor::flags{ .cxxflags = { "-std=c++20", "-O3", @@ -26,7 +26,7 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) "-fexceptions", }, }, - .externals = {"bar"}, + ctor::externals({"bar"}), } }; } diff --git a/test/suite/ctor_files/ctor.cc.base b/test/suite/ctor_files/ctor.cc.base index a8b3c92..f740659 100644 --- a/test/suite/ctor_files/ctor.cc.base +++ b/test/suite/ctor_files/ctor.cc.base @@ -11,12 +11,12 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) return { { - .name = "hello", - .target = "hello", - .sources = { + ctor::name("hello"), + ctor::target("hello"), + ctor::sources{ "hello.cc", }, - .flags = { + ctor::flags{ .cxxflags = { "-std=c++20", "-O3", @@ -26,7 +26,7 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) "-fexceptions", }, }, - .externals = {"bar"}, + ctor::externals({"bar"}), } }; } diff --git a/test/suite/ctor_files/ctor.cc.generated b/test/suite/ctor_files/ctor.cc.generated index d4b9786..1466e4d 100644 --- a/test/suite/ctor_files/ctor.cc.generated +++ b/test/suite/ctor_files/ctor.cc.generated @@ -13,11 +13,11 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) return { { - .target = "world", - .sources = { + ctor::target("world"), + ctor::sources{ { "world.cc", ctor::source_type::generated }, }, - .flags = { + ctor::flags{ .cxxflags = { "-std=c++20", "-O3", @@ -29,11 +29,11 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) }, }, { - .target = "foo", - .sources = { + ctor::target("foo"), + ctor::sources{ { "foo.cc", ctor::source_type::generated }, }, - .flags = { + ctor::flags{ .cxxflags = { "-std=c++20", "-O3", @@ -45,12 +45,12 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) }, }, { - .target = "this_is_unused", - .sources = { + ctor::target("this_is_unused"), + ctor::sources{ {"hello.cc", ctor::output_file{"world.cc"}}, {"hello.cc", ctor::output_file{"foo.cc"}}, }, - .function = [](const std::string& input, + ctor::GeneratorOneToOne{[](const std::string& input, const std::string& output, const ctor::build_configuration& config, const ctor::settings& settings) @@ -60,22 +60,22 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) std::cout << "Output: " << output << '\n'; fs::copy_file(input, output, fs::copy_options::overwrite_existing); return 0; - } + }} }, { - .target = "many_to_one", - .sources = { + ctor::target("many_to_one"), + ctor::sources{ {"many_to_one.cc", ctor::source_type::generated} } }, { - .target = "many_to_one.cc", - .sources = { + ctor::target("many_to_one.cc"), + ctor::sources{ {"foo.cc", ctor::source_type::generated}, {"hello.cc"}, }, - .function = [](const std::vector<std::string>& input, + ctor::GeneratorManyToOne{[](const std::vector<std::string>& input, const std::string& output, const ctor::build_configuration& config, const ctor::settings& settings) @@ -97,7 +97,7 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) } ofs << "*/\n"; return 0; - } + }} }, }; diff --git a/test/suite/ctor_files/ctor.cc.generated2 b/test/suite/ctor_files/ctor.cc.generated2 index c78489f..acda99f 100644 --- a/test/suite/ctor_files/ctor.cc.generated2 +++ b/test/suite/ctor_files/ctor.cc.generated2 @@ -13,24 +13,24 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) return { { - .target = "world", - .sources = { + ctor::target("world"), + ctor::sources{ { "world.cc", ctor::source_type::generated }, }, }, { - .target = "foo", - .sources = { + ctor::target("foo"), + ctor::sources{ { "foo.cc", ctor::source_type::generated }, }, }, { - .target = "this_is_unused", - .sources = { + ctor::target("this_is_unused"), + ctor::sources{ {"hello.cc", ctor::output_file{"world.cc"}}, {"hello.cc", ctor::output_file{"foo.cc"}}, }, - .function = [](const std::string& input, + ctor::GeneratorOneToOne{[](const std::string& input, const std::string& output, const ctor::build_configuration& config, const ctor::settings& settings) @@ -40,21 +40,21 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) std::cout << "Output: " << output << '\n'; fs::copy_file(input, output, fs::copy_options::overwrite_existing); return 0; - } + }} }, { - .target = "many_to_one", - .sources = { + ctor::target("many_to_one"), + ctor::sources{ {"many_to_one.cc", ctor::source_type::generated} } }, { - .target = "many_to_one.cc", - .sources = { + ctor::target("many_to_one.cc"), + ctor::sources{ {"hello.cc"}, }, - .function = [](const std::vector<std::string>& input, + ctor::GeneratorManyToOne{[](const std::vector<std::string>& input, const std::string& output, const ctor::build_configuration& config, const ctor::settings& settings) @@ -76,7 +76,7 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) } ofs << "*/\n"; return 0; - } + }} }, }; diff --git a/test/suite/ctor_files/ctor.cc.multi b/test/suite/ctor_files/ctor.cc.multi index 157d96c..419f982 100644 --- a/test/suite/ctor_files/ctor.cc.multi +++ b/test/suite/ctor_files/ctor.cc.multi @@ -13,12 +13,12 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) return { { - .name = "hello", - .target = "hello", - .sources = { + ctor::name("hello"), + ctor::target("hello"), + ctor::sources{ "hello.cc", }, - .flags = { + ctor::flags{ .cxxflags = { "-std=c++20", "-O3", @@ -28,7 +28,7 @@ ctor::build_configurations ctorConfigs(const ctor::settings& settings) "-fexceptions", }, }, - .externals = {"bar"}, + ctor::externals({"bar"}), } }; } |
