On Mon, Nov 11, 2013 at 11:55 AM, Eric Botcazou <ebotca...@adacore.com> wrote:
> Hi,
>
> in Ada 2012 it is allowed to omit components of aggregates (the equivalent of
> initializers/constructors); in this case, the contents of the corresponding
> fields in the record become undefined.  Now the gimplifier implements the C
> semantics of clearing the missing components, so this patch introduces a new
> flag on constructors to modify that.
>
> Tested on x86_64-suse-linux, OK for the mainline?

Ok.  Can you update doc/generic.texi?

Thanks,
Richard.

>
> 2013-11-11  Tristan Gingold  <ging...@adacore.com>
>             Eric Botcazou  <ebotca...@adacore.com>
>
>         * tree.h (CONSTRUCTOR_NO_CLEARING): Define.
>         * tree-core.h (CONSTRUCTOR_NO_CLEARING): Document it.
>         * tree.def (CONSTRUCTOR): Likewise.
>         * gimplify.c (gimplify_init_constructor): Do not clear the object when
>         the constructor is incomplete and CONSTRUCTOR_NO_CLEARING is set.
> ada/
>         * gcc-interface/utils2.c (gnat_build_constructor): Also set the flag
>         CONSTRUCTOR_NO_CLEARING on the constructor.
>
>
> --
> Eric Botcazou

Reply via email to