This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: [PATCH 3/6] float128: Add strfromf128


On Mon, 29 May 2017, Gabriel F. T. Gomes wrote:

> I attached a patch with this refactoring for double and long double.  I'll
> update this block for float128 in the next version of this patch.
> 
> Is the attached patch (with the refactoring) OK for master?

This refactoring patch is OK.

> > In other places you set is_binary128 even when !__HAVE_DISTINCT_FLOAT128.  
> > It's not *used* when !__HAVE_DISTINCT_FLOAT128 - is there a deliberate 
> > choice that in this place it shouldn't be set either?
> 
> The reason why I chose to not set it here, is because the struct info is
> zero'd by a memset some lines above (the narrowness of the diff context
> hid it):
> 
>   /* Prepare the format specification for printf_fp.  */    
>   memset (&info, '\0', sizeof (info));    
> 
> Would it be more clear to set it anyway?

Given the memset, it seems reasonable not to zero it again.

-- 
Joseph S. Myers
joseph@codesourcery.com


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