Skip to content

Commit 43eaa8f

Browse files
committed
Add first draft of Editors' Report N4661.
1 parent 1478337 commit 43eaa8f

File tree

1 file changed

+331
-0
lines changed

1 file changed

+331
-0
lines changed

papers/d4661.md

Lines changed: 331 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,331 @@
1+
# N4639 Editors' Report -- Programming Languages -- C++
2+
3+
2017-03-17
4+
Richard Smith (editor) (Google Inc)
5+
Dawn Perchik (co-editor) (Embarcadero Technologies Inc)
6+
Thomas Köppe (co-editor) (Google DeepMind)
7+
8+
9+
## Acknowledgements
10+
11+
Special thanks to
12+
the members of the editing committee for the C++17 DIS, namely
13+
Marshall Clow,
14+
Mike Miller,
15+
Ville Voutilainen,
16+
and
17+
Jeffrey Yasskin
18+
for their review of the correctness of the working paper
19+
as modified by the motions from the Kona 2017 meeting.
20+
21+
Special thanks also to
22+
Jonathan Wakely
23+
and
24+
Alisdair Meredith
25+
for performing edits and editorial review for several of the motions applied since N4640,
26+
and to
27+
Jens Maurer
28+
for performing many of the editorial fixes since N4640.
29+
30+
Thanks to all those who have [submitted editorial
31+
issues](https://github.com/cplusplus/draft/wiki/How-to-submit-an-editorial-issue)
32+
and to those who have provided pull requests with fixes.
33+
34+
## New papers
35+
36+
* [N4659](http://wg21.link/n4659) is the current working draft. It replaces [N4640](http://wg21.link/n4640).
37+
* [N4660](http://wg21.link/n4660) is the C++17 DIS.
38+
* N4661 is this Editors' Report.
39+
40+
The contents of N4659 and N4660 are identical except for the cover sheet and
41+
page headings.
42+
43+
## Motions incorporated into working draft and C++17 DIS
44+
45+
### Core working group motions
46+
47+
CWG motion 1: [Core issue resolutions](http://wg21.link/p0575r1) for 5 issues in "ready" status applied:
48+
49+
* [1677](http://wg21.link/cwg1677) Constant initialization via aggregate initialization
50+
* [1860](http://wg21.link/cwg1860) What is a "direct member?"
51+
* [2174](http://wg21.link/cwg2174) Unclear rules for friend definitions in templates
52+
* [2205](http://wg21.link/cwg2205) Restrictions on use of alignas
53+
* [2218](http://wg21.link/cwg2218) Ambiguity and namespace aliases
54+
55+
**The other 7 issues in "ready" status from P0575R1 were applied by CWG Motion 3**
56+
57+
CWG motion 2: [Core issue resolutions](http://wg21.link/p0576r1) for 5 issues in "tentatively ready" status applied:
58+
59+
* [2201](http://wg21.link/cwg2201) Cv-qualification of array types
60+
* [2206](http://wg21.link/cwg2206) Composite type of object and function pointers
61+
* [2214](http://wg21.link/cwg2214) Missing requirement on representation of integer values
62+
* [2220](http://wg21.link/cwg2220) Hiding index variable in range-based `for`
63+
* [2224](http://wg21.link/cwg2224) Member subobjects and base-class casts
64+
* [2259](http://wg21.link/cwg2259) Unclear context describing ambiguity
65+
* [2262](http://wg21.link/cwg2262) Attributes for *asm-definition*
66+
67+
CWG motion 3: [Core issue resolutions](http://wg21.link/p0622r0) for 12 issues in "ready" and "tentatively ready" status applied, resolving 13 issues:
68+
69+
* [426](http://wg21.link/cwg426) Identically-named variables, one internally and one externally linked, allowed?
70+
* [727](http://wg21.link/cwg727) In-class explicit specializations
71+
* [1622](http://wg21.link/cwg1622) Empty aggregate initializer for union (no changes, resolved by 2272)
72+
* [1710](http://wg21.link/cwg1710) Missing `template` keyword in *class-or-decltype*
73+
* [2196](http://wg21.link/cwg2196) Zero-initialization with virtual base classes
74+
* [2198](http://wg21.link/cwg2198) Linkage of enumerators
75+
* [2211](http://wg21.link/cwg2211) Hiding by lambda captures and parameters
76+
* [2247](http://wg21.link/cwg2247) Lambda capture and variable argument list
77+
* [2248](http://wg21.link/cwg2248) Problems with sized delete
78+
* [2251](http://wg21.link/cwg2251) Unreachable enumeration list-initialization
79+
* [2268](http://wg21.link/cwg2268) Unions with mutable members in constant expressions revisited
80+
* [2272](http://wg21.link/cwg2272) Implicit initialization of aggregate members of reference type
81+
* [2276](http://wg21.link/cwg2276) Dependent `noexcept` and function type-dependence
82+
83+
CWG motion 4: [P0612R0 "NB comment CH 2: volatile"](http://wg21.link/p0612r0), resolving 1 NB comment:
84+
85+
* CH 2: Clarify whether volatile semantics require volatile objects or merely volatile-qualified glvalues
86+
87+
CWG motion 5: [P0613R0 "NB comment GB15: Resolution of Core Issue 2011"](http://wg21.link/p0613r0), resolving 1 NB comment and 1 issue:
88+
89+
* GB 15, [2011](http://wg21.link/cwg2011) Unclear effect of reference capture of reference
90+
91+
CWG motion 6: [P0298R3 "A `byte` type definition"](http://wg21.link/p0298r3), resolving 3 NB comments:
92+
93+
* CA 11, US 72: Adopt [P0257R1 "A `byte` type for increased type safety"](http://wg21.link/p0257r1) with modifications
94+
* US 22: Adopt [P0298R1 "A `byte` type definition"](http://wg21.link/p0298r1)
95+
96+
CWG motion 7: [P0615R0 "Renaming for structured bindings"](http://wg21.link/p0615r0)
97+
98+
CWG motion 8: [P0620R0 "Drafting for class template argument deduction issues"](http://wg21.link/p0620r0), resolving 3 NB comments:
99+
100+
* US 94, GB 13, FI 21: Support class template argument deduction in `T{x1, x2, ...}` syntax
101+
102+
CWG motion 9: [P0270R3 "Removing C dependencies from signal handler wording"](http://wg21.link/p0270r3) **with changes, see below**, resolving 1 NB comment:
103+
104+
* CA 1: Adopt [P0270R1 "Removing C dependencies from signal handler wording"](http://wg21.link/p0270r1)
105+
106+
CWG motion 10: [P0250R3 "Wording improvements for initialization and thread ids"](http://wg21.link/p0250r3), resolving 2 issues in "concurrency" status:
107+
108+
* [1784](http://wg21.link/cwg1784) Concurrent execution during static local initialization
109+
* [2046](http://wg21.link/cwg2046) Incomplete thread specifications
110+
111+
CWG motion 11a applies to the Modules TS.
112+
113+
CWG motion 11b was not approved.
114+
115+
### Library working group motions
116+
117+
#### Issue resolutions
118+
119+
LWG motion 1 applies to the Coroutines TS.
120+
121+
LWG motion 2: [Library issue resolutions](http://wg21.link/p0165r4) for 22 issues in "Ready" and "Tentatively Ready" status applied, resolving 23 issues:
122+
123+
* [2260](http://wg21.link/lwg2260) Missing requirement for `Allocator::pointer`
124+
* [2768](http://wg21.link/lwg2768) `any_cast` and move semantics (no changes, resolved by 2769)
125+
* [2769](http://wg21.link/lwg2769) Redundant `const` in the return type of `any_cast(const any&)`
126+
* [2781](http://wg21.link/lwg2781) Contradictory requirements for `std::function` and `std::reference_wrapper`
127+
* [2782](http://wg21.link/lwg2782) `scoped_allocator_adaptor` constructors must be constrained
128+
* [2784](http://wg21.link/lwg2784) Resolution to [LWG 2484](http://wg21.link/lwg2484) is missing "otherwise, no effects" and is hard to parse
129+
* [2785](http://wg21.link/lwg2785) `quoted` should work with `basic_string_view`
130+
* [2786](http://wg21.link/lwg2786) Annex C should mention `shared_ptr` changes for array support
131+
* [2787](http://wg21.link/lwg2787) [file_status.cons] doesn't match class definition
132+
* [2789](http://wg21.link/lwg2789) Equivalence of contained objects
133+
* [2794](http://wg21.link/lwg2794) Missing requirements for allocator pointers
134+
* [2795](http://wg21.link/lwg2795) [global.functions] provides incorrect example of ADL use
135+
* [2804](http://wg21.link/lwg2804) Unconditional `constexpr` default constructor for `istream_iterator`
136+
* [2824](http://wg21.link/lwg2824) `list::sort` should say that the order of elements is unspecified if an exception is thrown
137+
* [2826](http://wg21.link/lwg2826) `string_view` iterators use old wording
138+
* [2834](http://wg21.link/lwg2834) Resolution to [LWG 2223](http://wg21.link/lwg2223) is missing wording about end iterators
139+
* [2835](http://wg21.link/lwg2835) Resolution to [LWG 2536](http://wg21.link/lwg2536) seems to misspecify `<tgmath.h>`
140+
* [2837](http://wg21.link/lwg2837) `gcd` and `lcm` should support a wider range of input values
141+
* [2838](http://wg21.link/lwg2838) `is_literal_type` specification needs a little cleanup
142+
* [2842](http://wg21.link/lwg2842) `in_place_t` check for `optional::optional(U&&)` should decay `U`
143+
* [2850](http://wg21.link/lwg2850) `std::function` move constructor does unnecessary work
144+
* [2853](http://wg21.link/lwg2853) Possible inconsistency in specification of `erase` in [vector.modifiers]
145+
* [2855](http://wg21.link/lwg2855) `std::throw_with_nested("string_literal")`
146+
147+
**Resolution of [2812](http://wg21.link/lwg2812) "Range access is available with `<string_view>`" not applied, as this issue had already been resolved editorially**
148+
149+
LWG motion 3: [Library issue resolutions](http://wg21.link/p0610r0) for 3 issues in "Review" status applied:
150+
151+
* [2676](http://wg21.link/lwg2676) Provide `filesystem::path` overloads for "File-based streams"
152+
* [2790](http://wg21.link/lwg2790) Missing specification of `istreambuf_iterator::operator->`
153+
* [2796](http://wg21.link/lwg2796) `tuple` should be a literal type
154+
155+
#### Filesystem
156+
157+
LWG motion 4: [P0317R1 "Directory entry caching for filesystem"](http://wg21.link/p0317r1) **with changes, see below**
158+
159+
LWG motion 5: [P0492R2 "Proposed resolution of C++17 National Body comments for filesystems"](http://wg21.link/p0492r2), resolving 31 NB comments and 2 issues:
160+
161+
* US 32: Meaning of [fs.conform.9945] unclear
162+
* US 33: Definition of "canonical path" problematic
163+
* US 34: Are there attributes of a file that are not an aspect of the file system?
164+
* US 36: Symbolic links themselves are attached to a directory via (hard) links
165+
* US 37: The term "redundant current directory (*dot*) elements" is not defined
166+
* US 43: Concerns about encoded character types
167+
* US 44, [2798](http://wg21.link/lwg2798): Definition of `path` in terms of a string requires leaky abstraction
168+
* US 45: Generic format portability compromised by unspecified *root-name* (no changes, resolved by US 73, CA 2)
169+
* US 46: *filename* can be empty so productions for *relative-path* are redundant
170+
* US 47: `.` and `..` already match the *name* production
171+
* US 48: Multiple separators are often meaningful in a *root-name*
172+
* US 51: Failing to add `/` when appending empty string prevents useful applications (no changes, resolved by US 74, CA 3)
173+
* US 52, [2665](http://wg21.link/lwg2665): `remove_filename` postcondition is not by itself a definition
174+
* US 53: `remove_filename`'s name does not correspond to its behavior (no changes, resolved by US 52, US 60)
175+
* US 54: `remove_filename` is broken
176+
* US 55: `replace_extension`'s use of `path` as parameter is inappropriate
177+
* US 58: `parent_path` behavior for root paths is useless (no changes, resolved by US 77, CA 6)
178+
* US 60: `path("/foo/").filename() == path(".")` is surprising
179+
* US 61: Leading dots in `filename` should not begin an extension (no changes, resolved by US 74, CA 3)
180+
* US 62: It is important that `stem() + extension() == filename()` (no changes, resolved by US 74, CA 3)
181+
* US 63: `lexically_normal` inconsistently treats trailing `/` but not `/..` as directory (no changes, resolved by US 37, US 74, CA 3)
182+
* US 73, CA 2: *root-name* is effectively implementation defined
183+
* US 74, CA 3: The term "pathname" is ambiguous in some contexts
184+
* US 77, CA 6: `operator/` and other `append`s not useful if arg has *root-name*
185+
* US 78, CA 7: Member `absolute` in [fs.op.absolute] is overspecified for non-POSIX-like O/S
186+
* Late 36: `permissions` `error_code` overload should be `noexcept` (no changes, resolved by Late 37)
187+
* Late 37: `permissions` actions should be separate parameter
188+
189+
LWG motion 6: [P0430R2 "File system library on non-POSIX-like operating systems"](http://wg21.link/p0430r2), resolving 6 NB comments:
190+
191+
* US 75, CA 4: Extra flag in `path` constructors is needed
192+
* US 76, CA 5: *root-name* definition is over-specified.
193+
* US 79, CA 8: Some operation functions are overspecified for implementation-defined file types
194+
195+
#### Parallel algorithms
196+
197+
LWG motion 7: [P0452R1 "Unifying `<numeric>` parallel algorithms"](http://wg21.link/p0452r1), partially resolving 2 NB comments:
198+
199+
* US 161: `inner_product` should use `*GENERALIZED_SUM*`
200+
* US 184: `inner_product` should not have `ExecutionPolicy` overload
201+
202+
LWG motion 8: [P0518R1 "Allowing copies as arguments to function objects given to parallel algorithms"](http://wg21.link/p0518r1), resolving 1 NB comment:
203+
204+
* CH 11: Allow parallel algorithms to make copies of their arguments
205+
206+
LWG motion 9: [P0523R1 "Complexity of parallel algorithms"](http://wg21.link/p0523r1), partially resolving 1 NB comment:
207+
208+
* CH 10: Relax complexity specifications for parallel algorithms
209+
210+
LWG motion 10: [P0574R1 "Algorithm complexity constraints and parallel overloads"](http://wg21.link/p0574r1), partially resolving 1 NB comment:
211+
212+
* CH 10: Relax complexity specifications for parallel algorithms
213+
214+
LWG motion 11: [P0467R2 "Iterator concerns for parallel algorithms"](http://wg21.link/p0467r2), partially resolving 2 NB comments:
215+
216+
* US 156: Relax iterator requirements for parallel algorithms
217+
* US 162: Relax parallel `adjacent_difference` specification to permit parallelization
218+
219+
LWG motion 12: [P0623R0 "Final C++17 parallel algorithms fixes"](http://wg21.link/p0623r0), partially resolving 3 NB comments:
220+
221+
* US 161: `inner_product` should use `*GENERALIZED_SUM*`
222+
* US 162: Relax parallel `adjacent_difference` specification to permit parallelization
223+
* US 184: `inner_product` should not have `ExecutionPolicy` overload
224+
225+
#### NB response papers
226+
227+
LWG motion 13: [P0604R0 "Resolving GB 55, US 84, US 85, US 86"](http://wg21.link/p0604r0), resolving 4 NB comments:
228+
229+
* GB 55, US 85: Fix `is_callable` and `result_of` to not use a function type as their interface
230+
* US 84: More clearly distinguish `*INVOKE(f, t1, t2, ..., tN)*` and `*INVOKE(f, t1, t2, ..., tN, R)*`
231+
* US 86: Rename `is_callable` to `is_invocable`
232+
233+
LWG motion 14: [P0607R0 "`inline` variables for the standard library"](http://wg21.link/p0607r0), resolving 2 NB comments:
234+
235+
* FI 9, GB28: Use `inline` variables for library tag types
236+
237+
LWG motion 15: [P0618R0 "Deprecating `<codecvt>`"](http://wg21.link/p0618r0), resolving 3 NB comments:
238+
239+
* GB 57: Deprecate `<codecvt>`
240+
* US 64, CA 9: Preserve references to UCS2
241+
242+
LWG motion 16: **Revert [P0181R1 "Ordered By Default"](http://wg21.link/p0181r1)**, applied by 2016-06 LWG Motion 21, resolving 1 NB comment:
243+
244+
* FI 18: Revert addition of `default_order`
245+
246+
LWG motion 17: [P0156R2 "Variadic lock guard"](http://wg21.link/p0156r2), resolving 2 NB comments:
247+
248+
* FI 8, GB 61: Revert making `lock_guard` variadic
249+
250+
LWG motion 18: [P0599R1 "`noexcept` for `hash` functions"](http://wg21.link/p0599r1), resolving 1 NB comment:
251+
252+
* US 140: Some or all `hash<T>` specializations should be `noexcept`
253+
254+
LWG motion 19: [P0433R2 "Integrating template deduction for class templates into the standard library"](http://wg21.link/p0433r2), resolving 2 NB comments and 3 issues:
255+
256+
* US 7, US 19 (remaining parts after P0512R0), US 147, US 148, US 150: Provide suitable deduction guides for the standard library
257+
258+
**Despite the claims of this paper and the wording of Motion 19,
259+
this paper is unrelated to US 14**
260+
261+
#### NB issue resolutions
262+
263+
LWG motion 20: [Library issue resolutions](http://wg21.link/p0625r0) for 23 issues in "Immediate" status applied, resolving 20 NB comments:
264+
265+
* CH 7, [2904](http://wg21.link/lwg2904): Make `variant` move-assignment more exception safe
266+
* GB 36, [2866](http://wg21.link/lwg2866): Incorrect derived classes constraints
267+
* GB 49, [2806](http://wg21.link/lwg2806): Base class of `bad_optional_access`
268+
* GB 53, [2807](http://wg21.link/lwg2807): `std::invoke` should use `std::is_nothrow_callable`
269+
* GB 54, [2868](http://wg21.link/lwg2868): Missing specification of `bad_any_cast::what()`
270+
* US 107, [2872](http://wg21.link/lwg2872): Add definition for "direct-non-list-initialization"
271+
* US 111, [2890](http://wg21.link/lwg2890): The definition of "object state" applies only to class types
272+
* US 111, [2900](http://wg21.link/lwg2900): The copy and move constructors of `optional` are not `constexpr`
273+
* US 118, [2903](http://wg21.link/lwg2903): The form of initialization for the emplace-constructors is not specified
274+
* US 122, [2801](http://wg21.link/lwg2801): Default-constructibility of `unique_ptr`
275+
* US 123, [2905](http://wg21.link/lwg2905): `is_constructible_v<unique_ptr<P | D> | P | D const &>` should be `false` when `D` is not copy constructible
276+
* US 124, [2873](http://wg21.link/lwg2873): Add `noexcept` to several `shared_ptr` related functions
277+
* US 125, [2874](http://wg21.link/lwg2874): Constructor `shared_ptr::shared_ptr(Y*)` should be constrained
278+
* US 126, [2875](http://wg21.link/lwg2875): `shared_ptr::shared_ptr(Y* | D | […])` constructors should be constrained
279+
* US 127, [2802](http://wg21.link/lwg2802): `shared_ptr` constructor requirements for a deleter
280+
* US 129, [2876](http://wg21.link/lwg2876): `shared_ptr::shared_ptr(const weak_ptr<Y>&)` constructor should be constrained
281+
* US 135, [2908](http://wg21.link/lwg2908): The less-than operator for shared pointers could do more
282+
* US 145, [2861](http://wg21.link/lwg2861): `basic_string` should require that `charT` match `traits::char_type`
283+
* US 153, [2878](http://wg21.link/lwg2878): Missing DefaultConstructible requirement for `istream_iterator` default constructor
284+
* US 165, [2921](http://wg21.link/lwg2921): `packaged_task` and type-erased allocators
285+
* [2788](http://wg21.link/lwg2788): `basic_string` range mutators unintentionally require a default constructible allocator
286+
* [2857](http://wg21.link/lwg2857): `{variant,optional,any}::emplace` should return the constructed value
287+
* [2934](http://wg21.link/lwg2934): `optional<const T>` doesn't compare with `T`
288+
289+
**Note: the resolutions of issues 2894 and 2911 in P0625R0 are not included in this motion**
290+
291+
LWG motion 20a was not approved.
292+
293+
LWG motion 20b: [Library issue resolution](http://wg21.link/p0625r0) for 1 issue in "Immediate" status applied, resolving 1 NB comment:
294+
295+
* US 143, [2911](http://wg21.link/lwg2911): An `is_aggregate_type` trait is needed
296+
297+
#### Non-NB-comment papers
298+
299+
LWG motion 21: [P0558R1 "Resolving `atomic<T>` named base class inconsistencies"](http://wg21.link/p0558r1)
300+
301+
LWG motion 22: [P0548R1 "`common_type` and `duration`"](http://wg21.link/p0548r1)
302+
303+
LWG motion 23 applies to the Ranges TS.
304+
305+
## Notable editorial changes
306+
307+
* CWG 6: In application of P0298R3, updated introductory sentence of [cstddef.syn]
308+
to avoid claiming that `std::byte` is part of ISO C's `<stddef.h>` header.
309+
310+
* CWG 9: Change to [csignal.syn] was not applied, because the desired normative
311+
effect had already been accomplished by [P0175R1](http://wg21.link/p0175r1),
312+
which was applied at the previous meeting and removed the baseline text for
313+
this change. The effect of the merge is that `std::signal` is *not* required
314+
to itself have C language linkage (but its parameter and returned function
315+
pointer types are). Also added subclause to house description of signal
316+
handlers, rather than including it in the `<csignal>` header synopsis.
317+
318+
* LWG 4: The normative description of `directory_entry::is_directory` is
319+
specified in terms of a non-existent `file_status` member, and either the
320+
`status` or `symlink_status` members could have been intended. After
321+
[consulting with LWG](http://lists.isocpp.org/lib/2017/03/2262.php),
322+
this usage of `file_status` has been replaced by `status`.
323+
324+
## Minor editorial fixes
325+
326+
A log of editorial fixes made since N4640 is below. This list excludes changes
327+
that do not affect the body text or only affect whitespace or typeface. For a
328+
complete list including such changes (or for the actual deltas applied by these
329+
changes), consult the [draft sources on github](https://github.com/cplusplus/draft/compare/n4640...n4659).
330+
331+
commit xxxxx

0 commit comments

Comments
 (0)