Skip to content

Commit 2a9dc35

Browse files
committed
test: regenerate regression tests
1 parent e929854 commit 2a9dc35

File tree

36 files changed

+142
-143
lines changed

36 files changed

+142
-143
lines changed

regression-tests/test-results/mixed-bounds-check.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
std::set_terminate(std::abort);
2525

2626
std::vector v {1, 2, 3, 4, 5, -999};
27-
CPP2_UFCS_0(pop_back, v);
27+
CPP2_UFCS(pop_back)(v);
2828
std::cout << cpp2::assert_in_bounds(std::move(v), 5) << "\n";
2929
}
3030

regression-tests/test-results/mixed-bounds-safety-with-assert-2.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ auto add_42_to_subrange(auto& rng, cpp2::in<int> start, cpp2::in<int> end) -> vo
3838
auto add_42_to_subrange(auto& rng, cpp2::in<int> start, cpp2::in<int> end) -> void
3939
{
4040
cpp2::Bounds.expects(cpp2::cmp_less_eq(0,start), "");
41-
cpp2::Bounds.expects(cpp2::cmp_less_eq(end,CPP2_UFCS_0(ssize, rng)), "");
41+
cpp2::Bounds.expects(cpp2::cmp_less_eq(end,CPP2_UFCS(ssize)(rng)), "");
4242

4343
auto count {0};
4444
for (

regression-tests/test-results/mixed-bounds-safety-with-assert.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ auto print_subrange(auto const& rng, cpp2::in<int> start, cpp2::in<int> end) ->
3737

3838
auto print_subrange(auto const& rng, cpp2::in<int> start, cpp2::in<int> end) -> void{
3939
cpp2::Bounds.expects(cpp2::cmp_less_eq(0,start), "");
40-
cpp2::Bounds.expects(cpp2::cmp_less_eq(end,CPP2_UFCS_0(ssize, rng)), "");
40+
cpp2::Bounds.expects(cpp2::cmp_less_eq(end,CPP2_UFCS(ssize)(rng)), "");
4141

4242
auto count {0};
4343
for (

regression-tests/test-results/mixed-captures-in-expressions-and-postconditions.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ auto insert_at(cpp2::in<int> where, cpp2::in<int> val) -> void
4545

4646
#line 22 "mixed-captures-in-expressions-and-postconditions.cpp2"
4747
{
48-
cpp2::Default.expects(cpp2::cmp_less_eq(0,where) && cpp2::cmp_less_eq(where,CPP2_UFCS_0(ssize, vec)), "");
49-
auto post_21_5 = cpp2::finally_success([_0 = CPP2_UFCS_0(ssize, vec)]{cpp2::Default.expects(CPP2_UFCS_0(ssize, vec) == _0 + 1, "");} );
48+
cpp2::Default.expects(cpp2::cmp_less_eq(0,where) && cpp2::cmp_less_eq(where,CPP2_UFCS(ssize)(vec)), "");
49+
auto post_21_5 = cpp2::finally_success([_0 = CPP2_UFCS(ssize)(vec)]{cpp2::Default.expects(CPP2_UFCS(ssize)(vec) == _0 + 1, "");} );
5050
#line 23 "mixed-captures-in-expressions-and-postconditions.cpp2"
51-
static_cast<void>(CPP2_UFCS(insert, vec, CPP2_UFCS_0(begin, vec) + where, val));
51+
static_cast<void>(CPP2_UFCS(insert)(vec, CPP2_UFCS(begin)(vec) + where, val));
5252
}
5353

regression-tests/test-results/mixed-fixed-type-aliases.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,6 @@ auto test(auto const& x) -> void{
4545
test(std::move(z));
4646

4747
for ( auto const& arg : args )
48-
std::cout << CPP2_UFCS_0(filename, std::filesystem::path(arg)) << "\n";
48+
std::cout << CPP2_UFCS(filename)(std::filesystem::path(arg)) << "\n";
4949
}
5050

regression-tests/test-results/mixed-function-expression-and-std-for-each.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,16 @@
3030

3131
// Passing a function expression
3232
std::for_each(
33-
CPP2_UFCS_0(begin, view),
34-
CPP2_UFCS_0(end, view),
33+
CPP2_UFCS(begin)(view),
34+
CPP2_UFCS(end)(view),
3535
[](auto& x) -> void { x += "-ish"; }
3636
);
3737

3838
// Initializing from a function expression
3939
auto callback {[](auto& x) -> void { x += " maybe"; }};
4040
std::for_each(
41-
CPP2_UFCS_0(begin, view),
42-
CPP2_UFCS_0(end, view),
41+
CPP2_UFCS(begin)(view),
42+
CPP2_UFCS(end)(view),
4343
std::move(callback)
4444
);
4545

regression-tests/test-results/mixed-function-expression-with-pointer-capture.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131

3232
std::string y {"\n"};
3333
std::ranges::for_each(view, [_0 = (&y)](auto const& x) -> void{
34-
std::cout << CPP2_UFCS_0(c_str, (*cpp2::assert_not_null((_0)))) << x << *cpp2::assert_not_null(_0);
34+
std::cout << CPP2_UFCS(c_str)((*cpp2::assert_not_null((_0)))) << x << *cpp2::assert_not_null(_0);
3535
});
3636

3737
auto callback {[](auto& x) -> void { x += "-ish"; }};

regression-tests/test-results/mixed-initialization-safety-3-contract-violation.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,9 @@ auto fill(
5959
) -> void
6060

6161
{
62-
cpp2::Default.expects(cpp2::cmp_greater_eq(CPP2_UFCS_0(ssize, value),count), "fill: value must contain at least count elements");
62+
cpp2::Default.expects(cpp2::cmp_greater_eq(CPP2_UFCS(ssize)(value),count), "fill: value must contain at least count elements");
6363
#line 25 "mixed-initialization-safety-3-contract-violation.cpp2"
64-
x.construct(CPP2_UFCS(substr, value, 0, count));
64+
x.construct(CPP2_UFCS(substr)(value, 0, count));
6565
}
6666

6767
auto print_decorated(auto const& x) -> void { std::cout << ">> [" << x << "]\n"; }

regression-tests/test-results/mixed-initialization-safety-3.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,9 @@ auto fill(
5454
) -> void
5555

5656
{
57-
cpp2::Default.expects(cpp2::cmp_greater_eq(CPP2_UFCS_0(ssize, value),count), "fill: value must contain at least count elements");
57+
cpp2::Default.expects(cpp2::cmp_greater_eq(CPP2_UFCS(ssize)(value),count), "fill: value must contain at least count elements");
5858
#line 23 "mixed-initialization-safety-3.cpp2"
59-
x.construct(CPP2_UFCS(substr, value, 0, count));
59+
x.construct(CPP2_UFCS(substr)(value, 0, count));
6060
}
6161

6262
auto print_decorated(auto const& x) -> void { std::cout << ">> [" << x << "]\n"; }

regression-tests/test-results/mixed-lifetime-safety-and-null-contracts.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ auto call_my_framework(char const* msg) -> void;
3434

3535
#line 6 "mixed-lifetime-safety-and-null-contracts.cpp2"
3636
[[nodiscard]] auto main() -> int{
37-
CPP2_UFCS(set_handler, cpp2::Null, &call_my_framework);
37+
CPP2_UFCS(set_handler)(cpp2::Null, &call_my_framework);
3838
try_pointer_stuff();
3939
std::cout << "done\n";
4040
}

regression-tests/test-results/mixed-postexpression-with-capture.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,9 @@ auto insert_at(cpp2::in<int> where, cpp2::in<int> val) -> void
4040

4141
#line 17 "mixed-postexpression-with-capture.cpp2"
4242
{
43-
cpp2::Default.expects(cpp2::cmp_less_eq(0,where) && cpp2::cmp_less_eq(where,CPP2_UFCS_0(ssize, vec)), "");
44-
auto post_16_5 = cpp2::finally_success([_0 = CPP2_UFCS_0(size, vec)]{cpp2::Default.expects(CPP2_UFCS_0(size, vec) == _0 + 1, "");} );
43+
cpp2::Default.expects(cpp2::cmp_less_eq(0,where) && cpp2::cmp_less_eq(where,CPP2_UFCS(ssize)(vec)), "");
44+
auto post_16_5 = cpp2::finally_success([_0 = CPP2_UFCS(size)(vec)]{cpp2::Default.expects(CPP2_UFCS(size)(vec) == _0 + 1, "");} );
4545
#line 18 "mixed-postexpression-with-capture.cpp2"
46-
CPP2_UFCS(push_back, vec, val);
46+
CPP2_UFCS(push_back)(vec, val);
4747
}
4848

regression-tests/test-results/mixed-postfix-expression-custom-formatting.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,12 @@ auto call([[maybe_unused]] auto const& param1, [[maybe_unused]] auto const& para
2828

2929
[[nodiscard]] auto test(auto const& a) -> std::string{
3030
return call(a,
31-
++*cpp2::assert_not_null(CPP2_UFCS(b, a, a.c)), "hello", /* polite
31+
++*cpp2::assert_not_null(CPP2_UFCS(b)(a, a.c)), "hello", /* polite
3232
greeting
3333
goes here */" there",
34-
CPP2_UFCS(e, a.d, ++CPP2_UFCS_0(g, *cpp2::assert_not_null(a.f)), // because f is foobar
35-
CPP2_UFCS_0(i, a.h),
36-
CPP2_UFCS(j, a, a.k, a.l))
34+
CPP2_UFCS(e)(a.d, ++CPP2_UFCS(g)(*cpp2::assert_not_null(a.f)), // because f is foobar
35+
CPP2_UFCS(i)(a.h),
36+
CPP2_UFCS(j)(a, a.k, a.l))
3737
);
3838
}
3939

regression-tests/test-results/mixed-string-interpolation.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ struct custom_struct_with_no_stringize_customization { } custom;
3030
std::cout << "a = " + cpp2::to_string(a) + ", b = " + cpp2::to_string(b) + "\n";
3131

3232
b = 42;
33-
std::cout << "a^2 + b = " + cpp2::to_string(a * std::move(a) + CPP2_UFCS_0(value, std::move(b))) + "\n";
33+
std::cout << "a^2 + b = " + cpp2::to_string(a * std::move(a) + CPP2_UFCS(value)(std::move(b))) + "\n";
3434

3535
std::string_view sv {"my string_view"};
3636
std::cout << "sv = " + cpp2::to_string(std::move(sv)) + "\n";

regression-tests/test-results/mixed-type-safety-1.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ auto print(cpp2::in<std::string> msg, cpp2::in<bool> b) -> void
5555
print( "1 is int? ", cpp2::is<int>(1));
5656

5757
auto c {cpp2_new<Circle>()}; // safe by construction
58-
Shape* s {CPP2_UFCS_0(get, c)}; // safe by Lifetime
58+
Shape* s {CPP2_UFCS(get)(c)}; // safe by Lifetime
5959
print("\ns* is Shape? ", cpp2::is<Shape>(*cpp2::assert_not_null(s)));
6060
print( "s* is Circle? ", cpp2::is<Circle>(*cpp2::assert_not_null(s)));
6161
print( "s* is Square? ", cpp2::is<Square>(*cpp2::assert_not_null(std::move(s))));

regression-tests/test-results/mixed-ufcs-multiple-template-arguments.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,6 @@ struct X {
3939
std::cout << substr<4,8>(test_string) << "\n";
4040

4141
X x {test_string};
42-
std::cout << CPP2_UFCS_TEMPLATE_0(substr, (<4,8>), std::move(x)) << "\n";
42+
std::cout << CPP2_UFCS_TEMPLATE(substr<4,8>)(std::move(x)) << "\n";
4343
}
4444

regression-tests/test-results/pure2-bounds-safety-span.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ auto print_and_decorate(auto const& thing) -> void;
3030
std::span<std::string> s {words};
3131

3232
auto i {0};
33-
for( ; cpp2::cmp_less(i,CPP2_UFCS_0(ssize, s)); ++i ) {
33+
for( ; cpp2::cmp_less(i,CPP2_UFCS(ssize)(s)); ++i ) {
3434
print_and_decorate(cpp2::assert_in_bounds(s, i));
3535
}
3636
}

regression-tests/test-results/pure2-enum.cpp

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11

2-
#define CPP2_USE_MODULES Yes
32

43
//=== Cpp2 type declarations ====================================================
54

@@ -158,7 +157,7 @@ inline constexpr skat_game skat_game::null = 23;
158157
return "invalid skat_game value";
159158
}
160159

161-
[[nodiscard]] auto operator<<(std::ostream& o, cpp2::in<skat_game> val) -> std::ostream&{o << CPP2_UFCS_0(to_string, val);return o; }
160+
[[nodiscard]] auto operator<<(std::ostream& o, cpp2::in<skat_game> val) -> std::ostream&{o << CPP2_UFCS(to_string)(val);return o; }
162161
inline constexpr cpp2::i8 rgb::enumeration_count = 3;
163162

164163
constexpr rgb::rgb(auto const& val)
@@ -190,7 +189,7 @@ inline constexpr rgb rgb::blue = 2;
190189
return "invalid rgb value";
191190
}
192191

193-
[[nodiscard]] auto operator<<(std::ostream& o, cpp2::in<rgb> val) -> std::ostream&{o << CPP2_UFCS_0(to_string, val);return o; }
192+
[[nodiscard]] auto operator<<(std::ostream& o, cpp2::in<rgb> val) -> std::ostream&{o << CPP2_UFCS(to_string)(val);return o; }
194193
inline constexpr cpp2::u8 file_attributes::enumeration_count = 4;
195194

196195
constexpr file_attributes::file_attributes(auto const& val)
@@ -241,7 +240,7 @@ inline constexpr file_attributes file_attributes::none = 0;
241240
return ret + ")";
242241
}
243242

244-
[[nodiscard]] auto operator<<(std::ostream& o, cpp2::in<file_attributes> val) -> std::ostream&{o << CPP2_UFCS_0(to_string, val);return o; }
243+
[[nodiscard]] auto operator<<(std::ostream& o, cpp2::in<file_attributes> val) -> std::ostream&{o << CPP2_UFCS(to_string)(val);return o; }
245244
#line 24 "pure2-enum.cpp2"
246245
auto main() -> int{
247246
// x : skat_game = 9; // error, can't construct skat_game from integer
@@ -253,8 +252,8 @@ auto main() -> int{
253252
// if x == 9 { } // error, can't compare skat_game and integer
254253
// if x == rgb::red { } // error, can't compare skat_game and rgb color
255254

256-
std::cout << "x.to_string() is " + cpp2::to_string(CPP2_UFCS_0(to_string, x)) + "\n";
257-
std::cout << "x2.to_string() is " + cpp2::to_string(CPP2_UFCS_0(to_string, std::move(x2))) + "\n";
255+
std::cout << "x.to_string() is " + cpp2::to_string(CPP2_UFCS(to_string)(x)) + "\n";
256+
std::cout << "x2.to_string() is " + cpp2::to_string(CPP2_UFCS(to_string)(std::move(x2))) + "\n";
258257
std::cout << "using << prints " << x << "\n";
259258

260259
std::cout << "with if else: ";
@@ -287,41 +286,41 @@ auto main() -> int{
287286

288287
x = skat_game::diamonds; // ok, can assign one skat_game from another
289288

290-
std::cout << "file_attributes::cached.get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, file_attributes::cached)) + "\n";
291-
std::cout << "file_attributes::current.get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, file_attributes::current)) + "\n";
292-
std::cout << "file_attributes::obsolete.get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, file_attributes::obsolete)) + "\n";
293-
std::cout << "file_attributes::cached_and_current.get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, file_attributes::cached_and_current)) + "\n";
289+
std::cout << "file_attributes::cached.get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(file_attributes::cached)) + "\n";
290+
std::cout << "file_attributes::current.get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(file_attributes::current)) + "\n";
291+
std::cout << "file_attributes::obsolete.get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(file_attributes::obsolete)) + "\n";
292+
std::cout << "file_attributes::cached_and_current.get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(file_attributes::cached_and_current)) + "\n";
294293

295294
file_attributes f {file_attributes::cached_and_current};
296295
f &= file_attributes::cached | file_attributes::obsolete;
297-
std::cout << "f. get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, f)) + "\n";
296+
std::cout << "f. get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(f)) + "\n";
298297

299298
auto f2 {file_attributes::cached};
300-
std::cout << "f2.get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, f2)) + "\n";
299+
std::cout << "f2.get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(f2)) + "\n";
301300

302301
std::cout << "f is " << f << "\n";
303302
std::cout << "f2 is " << f2 << "\n";
304303

305-
CPP2_UFCS(clear, f2, f2);
304+
CPP2_UFCS(clear)(f2, f2);
306305
std::cout << "f2 is " << f2 << "\n";
307-
CPP2_UFCS(set, f2, file_attributes::cached);
306+
CPP2_UFCS(set)(f2, file_attributes::cached);
308307
std::cout << "f2 is " << f2 << "\n";
309308

310-
std::cout << "f. get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, f)) + "\n";
311-
std::cout << "f2.get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, f2)) + "\n";
309+
std::cout << "f. get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(f)) + "\n";
310+
std::cout << "f2.get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(f2)) + "\n";
312311

313312
std::cout << "f is (f2) is " + cpp2::to_string(cpp2::is(f, (f2))) + "\n";
314313
std::cout << "f2 is (f ) is " + cpp2::to_string(cpp2::is(f2, (f))) + "\n\n";
315314

316-
CPP2_UFCS(clear, f, f2);
317-
CPP2_UFCS(set, f, file_attributes::current | f2);
315+
CPP2_UFCS(clear)(f, f2);
316+
CPP2_UFCS(set)(f, file_attributes::current | f2);
318317
f |= file_attributes::obsolete;
319318
f2 |= file_attributes::current;
320319

321320
std::cout << "f is " << f << "\n";
322321
std::cout << "f2 is " << f2 << "\n";
323-
std::cout << "f. get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, f)) + "\n";
324-
std::cout << "f2.get_raw_value() is " + cpp2::to_string(CPP2_UFCS_0(get_raw_value, f2)) + "\n";
322+
std::cout << "f. get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(f)) + "\n";
323+
std::cout << "f2.get_raw_value() is " + cpp2::to_string(CPP2_UFCS(get_raw_value)(f2)) + "\n";
325324
std::cout << "f == f2 is " + cpp2::to_string(f == f2 ) + "\n";
326325
std::cout << "f is (f2) is " + cpp2::to_string(cpp2::is(f, (f2))) + "\n";
327326
std::cout << "f2 is (f ) is " + cpp2::to_string(cpp2::is(f2, (f))) + "\n";

regression-tests/test-results/pure2-initialization-safety-with-else-if.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ auto main(int const argc_, char** argv_) -> int{
2525
auto c {3};
2626
auto d {4};
2727

28-
if (CPP2_UFCS_0(size, args) == 3) {
28+
if (CPP2_UFCS(size)(args) == 3) {
2929
p.construct(&a);
3030
}else {if (true) {
31-
if (CPP2_UFCS_0(size, args) == 2) {
31+
if (CPP2_UFCS(size)(args) == 2) {
3232
p.construct(&c);
3333
}else {if (cpp2::cmp_greater(std::move(b),0)) {
3434
p.construct(&a);

regression-tests/test-results/pure2-inspect-expression-in-generic-function-multiple-types.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ auto test_generic(auto const& x, auto const& msg) -> void;
2929
test_generic(a, "any");
3030
test_generic(o, "optional<int>");
3131

32-
static_cast<void>(CPP2_UFCS_TEMPLATE(emplace, (<0>), v, 1));
32+
static_cast<void>(CPP2_UFCS_TEMPLATE(emplace<0>)(v, 1));
3333
a = 2;
3434
o = 3;
3535
test_generic(42, "int");

regression-tests/test-results/pure2-intro-example-hello-2022.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ auto print_it(auto const& x, auto const& len) -> void;
3636

3737
[[nodiscard]] auto decorate(auto& thing) -> int{
3838
thing = "[" + thing + "]";
39-
return CPP2_UFCS_0(ssize, thing);
39+
return CPP2_UFCS(ssize)(thing);
4040
}
4141

4242
auto print_it(auto const& x, auto const& len) -> void {

regression-tests/test-results/pure2-intro-example-three-loops.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ auto decorate_and_print(auto& thing) -> void{
4242
std::span<std::string> view {words};
4343

4444
auto i {cpp2_new<int>(0)};
45-
for( ; cpp2::cmp_less(*cpp2::assert_not_null(i),CPP2_UFCS_0(ssize, view)); ++*cpp2::assert_not_null(i) ) {
45+
for( ; cpp2::cmp_less(*cpp2::assert_not_null(i),CPP2_UFCS(ssize)(view)); ++*cpp2::assert_not_null(i) ) {
4646
print(cpp2::assert_in_bounds(view, *cpp2::assert_not_null(i)));
4747
}
4848

regression-tests/test-results/pure2-stdio-with-raii.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@
2424
[[nodiscard]] auto main() -> int{
2525
std::string s {"Fred"};
2626
auto myfile {cpp2::fopen("xyzzy", "w")};
27-
static_cast<void>(CPP2_UFCS(fprintf, std::move(myfile), "Hello %s with UFCS!", CPP2_UFCS_0(c_str, std::move(s))));
27+
static_cast<void>(CPP2_UFCS(fprintf)(std::move(myfile), "Hello %s with UFCS!", CPP2_UFCS(c_str)(std::move(s))));
2828
}
2929

regression-tests/test-results/pure2-stdio.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
[[nodiscard]] auto main() -> int{
2727
std::string s {"Fred"};
2828
auto myfile {fopen("xyzzy", "w")};
29-
static_cast<void>(CPP2_UFCS(fprintf, myfile, "Hello %s with UFCS!", CPP2_UFCS_0(c_str, std::move(s))));
30-
static_cast<void>(CPP2_UFCS_0(fclose, std::move(myfile)));
29+
static_cast<void>(CPP2_UFCS(fprintf)(myfile, "Hello %s with UFCS!", CPP2_UFCS(c_str)(std::move(s))));
30+
static_cast<void>(CPP2_UFCS(fclose)(std::move(myfile)));
3131
}
3232

regression-tests/test-results/pure2-type-safety-1.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ auto print(cpp2::in<std::string> msg, cpp2::in<bool> b) -> void;
4141

4242
std::cout << "\n";
4343

44-
static_cast<void>(CPP2_UFCS_TEMPLATE(emplace, (<1>), v, 1));
44+
static_cast<void>(CPP2_UFCS_TEMPLATE(emplace<1>)(v, 1));
4545
a = 2;
4646
o = 3;
4747
test_generic(42, "int");

regression-tests/test-results/pure2-type-safety-2-with-inspect-expression.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ auto test_generic(auto const& x, auto const& msg) -> void;
2929
test_generic(a, "any");
3030
test_generic(o, "optional<int>");
3131

32-
static_cast<void>(CPP2_UFCS_TEMPLATE(emplace, (<2>), v, 1));
32+
static_cast<void>(CPP2_UFCS_TEMPLATE(emplace<2>)(v, 1));
3333
a = 2;
3434
o = 3;
3535
test_generic(42, "int");

regression-tests/test-results/pure2-types-basics.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -191,19 +191,19 @@ namespace N {
191191

192192
auto main() -> int{
193193
N::myclass x {1};
194-
CPP2_UFCS(f, x, 53);
194+
CPP2_UFCS(f)(x, 53);
195195
N::myclass::nested::g();
196-
std::cout << "f1: " + cpp2::to_string(CPP2_UFCS(f1, x, 1, 1)) + "\n";
197-
std::cout << "f2: " + cpp2::to_string(CPP2_UFCS(f2, x, 2, 2)) + "\n";
198-
std::cout << "f3: " + cpp2::to_string(CPP2_UFCS_TEMPLATE_0(f3, (<3,3>), x)) + "\n";
199-
std::cout << "f4: " + cpp2::to_string(CPP2_UFCS_TEMPLATE_0(f4, (<4,4>), x)) + "\n";
196+
std::cout << "f1: " + cpp2::to_string(CPP2_UFCS(f1)(x, 1, 1)) + "\n";
197+
std::cout << "f2: " + cpp2::to_string(CPP2_UFCS(f2)(x, 2, 2)) + "\n";
198+
std::cout << "f3: " + cpp2::to_string(CPP2_UFCS_TEMPLATE(f3<3,3>)(x)) + "\n";
199+
std::cout << "f4: " + cpp2::to_string(CPP2_UFCS_TEMPLATE(f4<4,4>)(x)) + "\n";
200200
N::myclass x2 {"abracadabra"};
201201
N::myclass x3 {};
202202
N::myclass x4 {1, "hair"};
203203

204204
// Invoke the single-param operator=s as actual assignments
205205
std::cout << "x's state before assignments: ";
206-
CPP2_UFCS_0(print, x);
206+
CPP2_UFCS(print)(x);
207207
x = 84;
208208
x = "syzygy";
209209
x = 84;

0 commit comments

Comments
 (0)