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/generated_sources_test.cc | |
| parent | 19d1dd34fbc87b6637147785332f180e36acdfef (diff) | |
New syntax
Diffstat (limited to 'test/generated_sources_test.cc')
| -rw-r--r-- | test/generated_sources_test.cc | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/test/generated_sources_test.cc b/test/generated_sources_test.cc index 8c46983..626a102 100644 --- a/test/generated_sources_test.cc +++ b/test/generated_sources_test.cc @@ -32,24 +32,24 @@ public: { return ctor::build_configurations{ { - .target = "test1", - .sources = { - {"foo.cc", ctor::source_type::generated} - } + ctor::target("test1"), + ctor::sources{ + {"foo.cc", ctor::source_type::generated} + }, }, { - .target = "this_is_unused", - .sources = { - {"bar.x", ctor::output_file{"foo.cc"}}, - {"bar.y", ctor::output_file{"bar.cc"}}, - }, - .function = []([[maybe_unused]]const std::string& input, - [[maybe_unused]]const std::string& output, - [[maybe_unused]]const ctor::build_configuration& config, - [[maybe_unused]]const ctor::settings& settings) + ctor::target("this_is_unused"), + ctor::sources{ + {"bar.x", ctor::output_file{"foo.cc"}}, + {"bar.y", ctor::output_file{"bar.cc"}}, + }, + ctor::GeneratorOneToOne([]([[maybe_unused]]const std::string& input, + [[maybe_unused]]const std::string& output, + [[maybe_unused]]const ctor::build_configuration& config, + [[maybe_unused]]const ctor::settings& settings) { return 0; - } + }), }, }; }); @@ -85,24 +85,24 @@ public: { return ctor::build_configurations{ { - .target = "test1", - .sources = { - {"foo.cc", ctor::source_type::generated} - } + ctor::target("test1"), + ctor::sources{ + {"foo.cc", ctor::source_type::generated} + }, }, { - .target = "foo.cc", - .sources = { - {"bar.x"}, - {"bar.y"}, - }, - .function = [](const std::vector<std::string>& input, - const std::string& output, - const ctor::build_configuration& config, - const ctor::settings& settings) + ctor::target("foo.cc"), + ctor::sources{ + {"bar.x"}, + {"bar.y"}, + }, + ctor::GeneratorManyToOne([](const std::vector<std::string>& input, + const std::string& output, + const ctor::build_configuration& config, + const ctor::settings& settings) { return 0; - } + }), }, }; }); |
