Subject: Re: [Boost-bugs] [Boost C++ Libraries] #10133: boost 1.55 breaks fusion map arrays
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-02-21 14:35:49
#10133: boost 1.55 breaks fusion map arrays
-------------------------------+------------------------
Reporter: steven.seeger@⦠| Owner: djowel
Type: Bugs | Status: new
Milestone: To Be Determined | Component: fusion
Version: Boost 1.55.0 | Severity: Regression
Resolution: | Keywords:
-------------------------------+------------------------
Comment (by Kohei Takahashi <flast@â¦>):
I believe that it is not a fusion's bug.
The constructor of `map` will take their arguments by Universal
References, like `template <class... T> map(T &&...)`, to accept any types
and any value categories, i.e. perfect forwarding.
However, compiler cannot deduce the argument type from brace-enclosed
initializer, see below.
n3337 14.8.2.1 [temp.deduct.call] p.1 sais:
If removing references
and cv-qualifiers from P gives std::initializer_list<P 0 > for some P 0
and the argument is an initializer
list (8.5.4), then deduction is performed instead for each element of
the initializer list, taking P 0 as a function
template parameter type and the initializer element as its argument.
Otherwise, an initializer list argument
causes the parameter to be considered a non-deduced context (14.8.2.5).
and 14.8.2.5 [temp.deduct.type] p.4 sais:
If a template parameter is used only in non-deduced
contexts and is not explicitly specified, template argument deduction
fails.
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/10133#comment:2> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:17 UTC