C++ Logo


Advanced search

Subject: Re: [std-proposals] Proposal of constpub (DRAFT 1)
From: Matthew Woehlke (mwoehlke.floss_at_[hidden])
Date: 2020-01-13 11:15:31

On 21/11/2019 05.33, Andrew Tomazos via Std-Proposals wrote:
> Please find attached a 2-page draft proposal entitled:
> Proposal of constpub
> It seems a little thing but easy to implement and I think it may have broad
> appeal.
> Anyway, initial thoughts appreciated.
> -Andrew.

I would rather see:

class foo
  using x = std::as_const(m_x);
  int m_x;

No new keywords, leverages the idea of "universal aliases", has more
possible uses...


STD-PROPOSALS list run by std-proposals-owner@lists.isocpp.org

Standard Proposals Archives on Google Groups