> In 0001-Ada-merge-all-timeval-and-timespec-definitions-and-c.patch:
> 
> > -   --  C timeval represent a duration (used in Select for example). This
> > -   --  structure is composed of a number of seconds and a number of micro
> > -   --  seconds. The timeval structure is not exposed here because its
> > -   --  definition is target dependent. Interface to C programs is done via 
> > a
> > -   --  pointer to timeval structure.
> > +   function To_Duration (T : not null access timeval)
> > +                        return System.C_Time.Non_Negative_Duration
> > +     with Inline
> > +   is (System.C_Time.To_Duration (T.all));
> > +   --  Deprecated.  Please use C_Time directly.
> 
> The aspect "with Inline" is incorrect, it should be last, after the
> return expression. The above does not build.
> 
> The obvious fix would be:
> 
>    function To_Duration (T : not null access timeval)
>                         return System.C_Time.Non_Negative_Duration
>    is (System.C_Time.To_Duration (T.all))
>      with Inline;

Note that expression functions are already marked inline-unless-impossible so 
you should simply drop the
Inline aspect.

> It may be surprising to have the RTEMS file used by other OS. The
> original comment should have mentionned that in the first place, but the
> file was only used with RTEMS. With your change, the file is effectively
> shared, so it would be best to rename it.

Agreed.

Reply via email to