Ping: [PATCH] Add inline bsearch expansion

Roland McGrath roland@hack.frob.com
Fri Feb 8 18:44:00 GMT 2013


> 	* bits/stdlib-bsearch.h: New file.
> 	* stdlib/bsearch.c: Include bits/stdlib-bsearch.h.
> 	* stdlib/stdlib.h(bsearch): Add inline bsearch.

Space before that paren.

> --- /dev/null
> +++ b/bits/stdlib-bsearch.h
> @@ -0,0 +1,28 @@
> +#ifdef __USE_EXTERN_INLINES

Every file needs the standard header comment (descriptive first line, then
the standard copyright text).  Since the contents are copied from
bsearch.c, use the same copyright year range that's already in that file.

Don't put that #ifdef inside this file.
Instead, conditionalize its inclusion in stdlib.h.

> diff --git a/stdlib/bsearch.c b/stdlib/bsearch.c
> index 55b4f37..04a9d9d 100644
> --- a/stdlib/bsearch.c
> +++ b/stdlib/bsearch.c
> @@ -1,4 +1,4 @@
> -/* Copyright (C) 1991-2013 Free Software Foundation, Inc.
> +/* Copyright (C) 2013 Free Software Foundation, Inc.

Never remove old years from an existing copyright notice like this.


Thanks,
Roland



More information about the Libc-alpha mailing list