Fair enough.

But with the difference that a classical getter would be by value and that one would return a const reference.
 

-----Ursprüngliche Nachricht-----
Von: Robin Savonen Söderholm <robinsavonensoderholm@gmail.com>
Gesendet: Mo 16.12.2024 13:33
Betreff: Re: [std-proposals] New access specifiers
An: std-proposals@lists.isocpp.org;
CC: Sebastian Wittmeier <wittmeier@projectalpha.org>;

That would be a getter, which the OP was trying to avoid... I guess the OP would like to declare things that looks like 'member fields' but in reality are 'member functions'. Not sure how that would end up though.

// Robin