Skip to content

Commit

Permalink
New issue from Eric Niebler: ""Required behavior" too narrowly defined"
Browse files Browse the repository at this point in the history
  • Loading branch information
Dani-Hub committed Nov 4, 2023
1 parent 50998c7 commit b596ffb
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions xml/issue4005.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<?xml version='1.0' encoding='utf-8' standalone='no'?>
<!DOCTYPE issue SYSTEM "lwg-issue.dtd">

<issue num="4005" status="New">
<title>"Required behavior" too narrowly defined</title>
<section><sref ref="[defns.required.behavior]"/><sref ref="[structure.specifications]"/><sref ref="[res.on.functions]"/></section>
<submitter>Eric Niebler</submitter>
<date>03 Nov 2023</date>
<priority>99</priority>

<discussion>
<p>
The library's definition of the term "required behavior" (<sref ref="[defns.required.behavior]"/>) makes it specific to
certain replaceable functions such as the replaceable global allocation functions. Notably, it is not one of the elements
that are allowed to appear in the descriptions of general function semantics. That is, it isn't in the list in
<sref ref="[structure.specifications]"/> p3.
<p/>
However, the specification of the random number generator library uses "Required behavior" as such a descriptive element
of its functions' semantics (e.g., <sref ref="[rand.predef]"/>).
<p/>
I think that's a fine use of "Required behavior", so I would like the term to be more generally applicable to the behavior
of any stdlib function that may be customized by users. This is relevant for <tt>std::execution</tt>, where algorithms are
customizable but the customizations are required to behave a certain way.
<p/>
<b>Daniel:</b>
<p/>
Bullet (2.4) of <sref ref="[res.on.functions]"/> also contradicts to the more narrow definition of
<sref ref="[defns.required.behavior]"/> by suddenly extending it to "destructor operations".
</p>
</discussion>

<resolution>
</resolution>

</issue>

0 comments on commit b596ffb

Please sign in to comment.