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: [WIP] Remove nested function in elf/dl-lookup.c? (Nested functions considered harmful?)


On Sat, Dec 14, 2013 at 10:58:46AM -0500, Carlos O'Donell wrote:
> Is it me or does reading do_lookup_x get very very complicated
> with the nested function check_match which has access to all
> sorts of function local variables?
> 
> I'm always suspicious of nested functions like this as bad
> programming form since it complicates reading the function.
> 
> Is anyone opposed to rewriting this with a non-nested function
> that clearly shows which arguments are constant, and which are
> modified?
> 
I am for that. Could you show that in this is only refactoring, when
do_lookup_x is always_inlined then both binaries should be same.


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