Hi!

On Thu, Apr 02, 2020 at 10:28:34AM +0200, Jakub Jelinek wrote:
> > +                   tree offset = dataref_offset
> > +                                   ? dataref_offset
> > +                                   : build_int_cst (ref_type, 0);
> 
> The above is misformatted.  The ? and : shouldn't be indented further than
> the dataref_offset, but usually e.g. for the sake of emacs we add ()s around
> the expression in this case.  So:
>                       tree offset = (dataref_offset
>                                      ? dataref_offset
>                                      : build_int_cst (ref_type, 0));
> or
>                       tree offset
>                         = (dataref_offset
>                            ? dataref_offset : build_int_cst (ref_type, 0));

Or even just the (less obfuscated imnsho)

                        tree offset = dataref_offset;
                        if (!offset)
                          offset = build_int_cst (ref_type, 0);

which even is shorter!


Segher

Reply via email to