This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [C++ patch] Allow p->~T() when T is a vector


On Thu, Aug 2, 2012 at 7:08 AM, Richard Guenther
<richard.guenther@gmail.com> wrote:
> On Thu, Aug 2, 2012 at 1:42 PM, Marc Glisse <marc.glisse@inria.fr> wrote:
>> Hello,
>>
>> this patch allows p->~T() when T is (after substitution) a vector, which is
>> necessary for use in std::vector for instance.
>
> Why not include VECTOR_TYPE in ARITHMETIC_TYPE_P?

We have decided long ago that abstractions in the compiler
should use names and semantics following the standard texts
so that reading the source code should not reserve surprises
to anyone familiar with the standards, hence minimize help
subtle bugs and reduce efforts needed to understand the compiler.
Putting VECTOR_TYPE in ARITHMETIC_TYPE_P violates that
common sense principle.

-- Gaby


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]