Date: Sun, 22 Dec 2019 13:50:55 -0800
> On Dec 22, 2019, at 11:41 AM, Nevin Liber via SG20 <sg20_at_[hidden]> wrote:
>
> On Sun, Dec 22, 2019 at 11:48 AM Jon Kalb via SG20 <sg20_at_[hidden] <mailto:sg20_at_[hidden]>> wrote:
>
> There are two cases, what Herb calls “tracking” and “making the type stick.” I think I’d call them “tracking” and “fixing.” I think they should be spelled:
>
> auto x{expr}; // tracking - we want x to be whatever expr returns, even if it is changed by maintenance
>
> The callee decides the type.
>
> auto x{type{expr}}; // fixing - we want x to be type regardless of what expr returns.
>
> The caller decides the type.
>
> I don’t see any other case.
>
> The case that isn't here is the no surprises case when you want the caller type and the callee type to match an explicitly mentioned type.
Then make a static assertion.
> --
> Nevin ":-)" Liber <mailto:nevin_at_[hidden] <mailto:nevin_at_[hidden]>> +1-847-691-1404
> --
> SG20 mailing list
> SG20_at_[hidden]
> https://lists.isocpp.org/mailman/listinfo.cgi/sg20
>
> On Sun, Dec 22, 2019 at 11:48 AM Jon Kalb via SG20 <sg20_at_[hidden] <mailto:sg20_at_[hidden]>> wrote:
>
> There are two cases, what Herb calls “tracking” and “making the type stick.” I think I’d call them “tracking” and “fixing.” I think they should be spelled:
>
> auto x{expr}; // tracking - we want x to be whatever expr returns, even if it is changed by maintenance
>
> The callee decides the type.
>
> auto x{type{expr}}; // fixing - we want x to be type regardless of what expr returns.
>
> The caller decides the type.
>
> I don’t see any other case.
>
> The case that isn't here is the no surprises case when you want the caller type and the callee type to match an explicitly mentioned type.
Then make a static assertion.
> --
> Nevin ":-)" Liber <mailto:nevin_at_[hidden] <mailto:nevin_at_[hidden]>> +1-847-691-1404
> --
> SG20 mailing list
> SG20_at_[hidden]
> https://lists.isocpp.org/mailman/listinfo.cgi/sg20
Received on 2019-12-22 15:53:24