Title
std::function Effects clause impossible to satisfy
Status
resolved
Section
[func.wrap.func.mod]
Submitter
Daniel Krügler

Created on 2009-11-05.00:00:00 last changed 163 months ago

Messages

Date: 2010-10-21.18:28:33

[ Question to the editor: Shouldn't there a paragraph number in front of the Effects clause? ]

template<class F, Allocator Allocclass A>
  void assign(F f, const Alloc& a);

3 Effects: function(f, aallocator_arg, a, f).swap(*this)

Date: 2010-10-21.18:28:33

Proposed resolution:

Change in [func.wrap.func.mod] the complete prototype description as indicated

Date: 2010-02-11.00:00:00

[ 2010-02-11 Moved to Tentatively NAD Editorial after 5 positive votes on c++std-lib. It was noted that this issue was in partial conflict with 1288, and the two issues were merged in 1288. ]

Addressed by 1288.

Date: 2009-11-15.00:00:00

[ 2009-11-15 Moved to Tentatively Ready after 5 positive votes on c++std-lib. ]

Date: 2009-11-13.00:00:00

[ 2009-11-13 Daniel brought wording up to date. ]

Date: 2009-11-05.00:00:00

As of [func.wrap.func.mod]/2+ we have the following prototype description:

template<class F, Allocator Alloc>
  void assign(F, const Alloc&);

Effects: function(f, a).swap(*this)

Two things: First the concept debris needs to be removed, second and much more importantly, the effects clause is now impossible to satisfy, because there is no constructor that would match the parameter sequence (FunctionObject, Allocator) [plus the fact that no f and no a is part of the signature]. The most probable candidate is

template<class F, class A> function(allocator_arg_t, const A&, F);

and the effects clause needs to be adapted to use this signature.

History
Date User Action Args
2010-11-19 19:04:45adminsetstatus: nad editorial -> resolved
2010-10-21 18:28:33adminsetmessages: + msg1346
2010-10-21 18:28:33adminsetmessages: + msg1345
2010-10-21 18:28:33adminsetmessages: + msg1344
2010-10-21 18:28:33adminsetmessages: + msg1343
2010-10-21 18:28:33adminsetmessages: + msg1342
2009-11-05 00:00:00admincreate