<div dir="ltr"><div>On Wed, 30 Jan 2019 at 17:47 Jens Maurer &lt;<a href="mailto:Jens.Maurer@gmx.net" target="_blank">Jens.Maurer@gmx.net</a>&gt; wrote:<br></div><div dir="ltr"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 01/30/2019 10:37 AM, John McFarlane wrote:<br>
&gt; Can I take this opportunity to recommend that we consider library solutions to our numerics problems? There are mature, widely used class-based literal types out there which tackle such problems. (And yes, they support wrap, trap, snap and crap.) We could put a lot more effort into exploring their standardization. <br>
<br>
I thought SG6 was working on that.  There were design overview<br>
papers discussed in SG6 at some Kona meeting years ago.<br>
<br>
Where did that go?<br></blockquote><div><br></div><div>Briefly, from what I recall of the last few years&#39; submissions...</div><div><br></div><div>In 2015, Lawrence proposed a Numerics TS in P0101 including an overflow-handling type in P0106 (including wrap, trap and snap). There was also P0105 which proposed free arithmetic functions to handle overflow in fundamental types.</div></div></div><div dir="ltr"><div class="gmail_quote"><div><br></div><div>Robert Ramey proposed a safe integer type in 2016 in P0288 then decided that taking the Boost route would have more impact.</div><div><br></div>In 2017, P0105 was revised. That same year, I wrote a position paper, P0554, aimed at selling the idea of separating out P0106 types into different single-responsibility types. It included a fairly typical &#39;safe integer&#39; type not dissimilar to Robert&#39;s.<div><br></div><div>Last year, Federico Kircheis published a safe integral comparisons papers which overlaps the problem space of P0105. And I published P0828 with a type which widens its results to avoid overflow. (Both Robert&#39;s and Lawrence&#39;s types offer this.)</div><br class="m_-6172965216576954998inbox-inbox-Apple-interchange-newline"><div>That&#39;s about all I&#39;ve seen happening in this space in four years. No other evidence of a Numerics TS and only a handful of proposals that might live in it if there was. But there is some demand for safer integers. The problem space is well explored with a good few solutions in the public domain including from Microsoft and LLVM. (Other languages such as Swift, Rust and Python are doing great things here too.)</div><div><br></div><div>John</div></div></div><div dir="ltr"><div><div class="gmail_quote"><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Jens<br>
<br>
_______________________________________________<br>
ub mailing list<br>
<a href="mailto:ub@isocpp.open-std.org" target="_blank">ub@isocpp.open-std.org</a><br>
<a href="http://www.open-std.org/mailman/listinfo/ub" rel="noreferrer" target="_blank">http://www.open-std.org/mailman/listinfo/ub</a><br>
</blockquote></div></div></div></div>