Skip to content

Commit

Permalink
New issue from Thomas: "Clarify whether arithmetic expressions in [nu…
Browse files Browse the repository at this point in the history
…meric.sat.func] are mathematical or C+"
  • Loading branch information
Dani-Hub committed Dec 22, 2023
1 parent cfce831 commit cbcf6fe
Showing 1 changed file with 51 additions and 0 deletions.
51 changes: 51 additions & 0 deletions xml/issue4030.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<?xml version='1.0' encoding='utf-8' standalone='no'?>
<!DOCTYPE issue SYSTEM "lwg-issue.dtd">

<issue num="4030" status="New">
<title>Clarify whether arithmetic expressions in [numeric.sat.func] are mathematical or C++</title>
<section><sref ref="[numeric.sat.func]"/></section>
<submitter>Thomas K&ouml;ppe</submitter>
<date>18 Dec 2023</date>
<priority>99</priority>

<discussion>
<p>
During the application of <paper num="P0543R0"/>, "Saturation arithmetic", it was pointed out that it
might not be entirely clear what we want something like "<tt>x</tt> + <tt>y</tt>" to mean. The paper does not
suggest any formatting for those symbols, and a non-normative note explains that the intention is for
the expression to be considered mathematically.
<p/>
I wonder if this is clear enough. Notes are not normative, and the document "shall be usable without notes".
I have formatted this as <tt>$\tcode{x} + \tcode{y}$</tt> throughout, i.e. the variables are in code font,
but the symbol is maths, not code. This is quite subtle. (See also
<a href="https://github.com/cplusplus/draft/pull/6686">GitHub discussion</a>.)
<p/>
I think it would be an improvement if we simply made the note not be a note. It seems to contain entirely reasonable, mandatory content.
</p>
</discussion>

<resolution>
<p>
This wording is relative to <paper num="N4971"/>.
</p>

<ol>

<li><p>Modify <sref ref="[numeric.sat.func]"/> as indicated:</p>

<blockquote>
<p>
-1- <del>[<i>Note 1</i>:</del> In the following descriptions, an arithmetic operation is performed as a mathematical
operation with infinite range and then it is determined whether the mathematical result fits into the result type.
<del>&mdash; <i>end note</i>]</del>
</p>
</blockquote>

</li>

</ol>


</resolution>

</issue>

0 comments on commit cbcf6fe

Please sign in to comment.