This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: Fix compilation errors with libstdc++v3 for AVR target and allow --enable-libstdcxx
- From: Felipe Magno de Almeida <felipe dot m dot almeida at gmail dot com>
- To: libstdc++ at gcc dot gnu dot org
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Fri, 16 Sep 2016 02:53:06 -0300
- Subject: Re: Fix compilation errors with libstdc++v3 for AVR target and allow --enable-libstdcxx
- Authentication-results: sourceware.org; auth=none
- References: <CADfx-VSmfye0Xe7xMWVFZKDZhQbwFcw7RbNYe=6irDJUzPtHzg@mail.gmail.com> <alpine.DEB.2.20.1609160733190.3301@laptop-mg.saclay.inria.fr>
On Fri, Sep 16, 2016 at 2:42 AM, Marc Glisse <marc.glisse@inria.fr> wrote:
> On Thu, 15 Sep 2016, Felipe Magno de Almeida wrote:
>
> + || sizeof(uint32_t) == sizeof(void*)
> + || sizeof(uint16_t) == sizeof(void*),
>
> Indentation is off?
>
>> Call _M_extract_* functions family through temporary int objects
>
>
> Would it make sense to use a template type instead of int for this
> parameter? Or possibly have a typedef that defaults to int (what POSIX
> requires). The hard case would be a libc that uses bitfields for the fields
> of struct tm (that could save some space), but I don't think anyone does
> that.
I've tried both approaches. Templates were causing problems of not
defined instantations because they were being used as ints too
in other _M_extract functions through a tmp integer. And typedef's
caused the same problem of having to use a tmp value of the right
type but for example _M_extract_wday_or_month could not have the
same type (in AVR they do) and I'd have to use a temporary anyway
then.
This was the least intrusive way.
>> float pointing
>
> floating point?
:D. Yes.
> A ChangeLog entry would also help.
OK.
> --
> Marc Glisse
Regards,
--
Felipe Magno de Almeida