File tree Expand file tree Collapse file tree 2 files changed +13
-8
lines changed
Expand file tree Collapse file tree 2 files changed +13
-8
lines changed Original file line number Diff line number Diff line change @@ -12,10 +12,10 @@ ns: namespace = {
1212f: (_) -> int == 1;
1313} // namespace ns
1414
15- // v: @struct type = {
16- // f :== :(_) 0; // Pending on #706.
17- // g: (i) i.f();
18- // }
15+ v: @struct type = {
16+ f :== :(_) 0;
17+ g: (i) i.f();
18+ }
1919
2020main: () = {
2121 {
Original file line number Diff line number Diff line change @@ -22,6 +22,8 @@ namespace ns {
2222
2323}
2424
25+ class v ;
26+
2527
2628// === Cpp2 type definitions and function declarations ===========================
2729
@@ -41,10 +43,10 @@ namespace ns {
4143[[nodiscard]] constexpr auto f ([[maybe_unused]] auto const & unnamed_param_1) -> int;
4244} // namespace ns
4345
44- // v: @struct type = {
45- // f :== :(_) 0; // Pending on #706.
46- // g: (i) i.f() ;
47- // }
46+ class v {
47+ public: static constexpr auto f = []([[maybe_unused]] auto const & unnamed_param_1) mutable -> auto { return 0 ; };
48+ public: [[nodiscard]] static auto g ( auto const & i) -> auto ;
49+ };
4850
4951auto main () -> int;
5052
@@ -63,6 +65,9 @@ namespace ns {
6365[[nodiscard]] constexpr auto f ([[maybe_unused]] auto const & unnamed_param_1) -> int { return 1 ; }
6466}
6567
68+ #line 17 "pure2-bugfix-for-ufcs-name-lookup.cpp2"
69+ [[nodiscard]] auto v::g (auto const & i) -> auto { return CPP2_UFCS (f)(i); }
70+
6671#line 20 "pure2-bugfix-for-ufcs-name-lookup.cpp2"
6772auto main () -> int{
6873 {
You can’t perform that action at this time.
0 commit comments