Mercurial > hg > octave-nkf > gnulib-hg
changeset 15418:e434caaeadb1
Rename module 'unused-parameter' to 'snippet/unused-parameter'.
* modules/snippet/unused-parameter: Renamed from
modules/unused-parameter.
(Files, Makefile.am): Update.
* build-aux/snippet/unused-parameter.h: Renamed from
build-aux/unused-parameter.h.
* modules/selinux-h (Depends-on): Update.
* modules/unistr/base (Depends-on): Update.
* MODULES.html.sh (Core language properties): Update.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Tue, 12 Jul 2011 11:43:19 +0200 |
parents | 3c3c5ba60033 |
children | d2437ed29d20 |
files | ChangeLog MODULES.html.sh build-aux/snippet/unused-parameter.h build-aux/unused-parameter.h modules/selinux-h modules/snippet/unused-parameter modules/unistr/base modules/unused-parameter |
diffstat | 8 files changed, 91 insertions(+), 79 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,15 @@ +2011-07-12 Bruno Haible <bruno@clisp.org> + + Rename module 'unused-parameter' to 'snippet/unused-parameter'. + * modules/snippet/unused-parameter: Renamed from + modules/unused-parameter. + (Files, Makefile.am): Update. + * build-aux/snippet/unused-parameter.h: Renamed from + build-aux/unused-parameter.h. + * modules/selinux-h (Depends-on): Update. + * modules/unistr/base (Depends-on): Update. + * MODULES.html.sh (Core language properties): Update. + 2011-07-12 Bruno Haible <bruno@clisp.org> Rename module 'link-warning' to 'snippet/link-warning'.
--- a/MODULES.html.sh +++ b/MODULES.html.sh @@ -2012,7 +2012,7 @@ func_module func func_module inline func_module longlong - func_module unused-parameter + func_module snippet/unused-parameter func_module va-args func_module vararrays func_end_table
new file mode 100644 --- /dev/null +++ b/build-aux/snippet/unused-parameter.h @@ -0,0 +1,36 @@ +/* A C macro for declaring that specific function parameters are not used. + Copyright (C) 2008-2011 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as published + by the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public License + along with this program. If not, see <http://www.gnu.org/licenses/>. */ + +/* _GL_UNUSED_PARAMETER is a marker that can be appended to function parameter + declarations for parameters that are not used. This helps to reduce + warnings, such as from GCC -Wunused-parameter. The syntax is as follows: + type param _GL_UNUSED_PARAMETER + or more generally + param_decl _GL_UNUSED_PARAMETER + For example: + int param _GL_UNUSED_PARAMETER + int *(*param)(void) _GL_UNUSED_PARAMETER + Other possible, but obscure and discouraged syntaxes: + int _GL_UNUSED_PARAMETER *(*param)(void) + _GL_UNUSED_PARAMETER int *(*param)(void) + */ +#ifndef _GL_UNUSED_PARAMETER +# if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7) +# define _GL_UNUSED_PARAMETER __attribute__ ((__unused__)) +# else +# define _GL_UNUSED_PARAMETER +# endif +#endif
deleted file mode 100644 --- a/build-aux/unused-parameter.h +++ /dev/null @@ -1,36 +0,0 @@ -/* A C macro for declaring that specific function parameters are not used. - Copyright (C) 2008-2011 Free Software Foundation, Inc. - - This program is free software: you can redistribute it and/or modify it - under the terms of the GNU Lesser General Public License as published - by the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public License - along with this program. If not, see <http://www.gnu.org/licenses/>. */ - -/* _GL_UNUSED_PARAMETER is a marker that can be appended to function parameter - declarations for parameters that are not used. This helps to reduce - warnings, such as from GCC -Wunused-parameter. The syntax is as follows: - type param _GL_UNUSED_PARAMETER - or more generally - param_decl _GL_UNUSED_PARAMETER - For example: - int param _GL_UNUSED_PARAMETER - int *(*param)(void) _GL_UNUSED_PARAMETER - Other possible, but obscure and discouraged syntaxes: - int _GL_UNUSED_PARAMETER *(*param)(void) - _GL_UNUSED_PARAMETER int *(*param)(void) - */ -#ifndef _GL_UNUSED_PARAMETER -# if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7) -# define _GL_UNUSED_PARAMETER __attribute__ ((__unused__)) -# else -# define _GL_UNUSED_PARAMETER -# endif -#endif
--- a/modules/selinux-h +++ b/modules/selinux-h @@ -10,7 +10,7 @@ Depends-on: errno -unused-parameter +snippet/unused-parameter configure.ac: gl_HEADERS_SELINUX_SELINUX_H
new file mode 100644 --- /dev/null +++ b/modules/snippet/unused-parameter @@ -0,0 +1,40 @@ +Description: +A C macro for declaring that specific function parameters are not used. + +Applicability: +all + +Files: +build-aux/snippet/unused-parameter.h + +Depends-on: + +configure.ac: + +Makefile.am: +# The BUILT_SOURCES created by this Makefile snippet are not used via #include +# statements but through direct file reference. Therefore this snippet must be +# present in all Makefile.am that need it. This is ensured by the applicability +# 'all' defined above. + +BUILT_SOURCES += unused-parameter.h +# The unused-parameter.h that gets inserted into generated .h files is the same +# as build-aux/snippet/unused-parameter.h, except that it has the copyright +# header cut off. +unused-parameter.h: $(top_srcdir)/build-aux/snippet/unused-parameter.h + $(AM_V_GEN)rm -f $@-t $@ && \ + sed -n -e '/GL_UNUSED_PARAMETER/,$$p' \ + < $(top_srcdir)/build-aux/snippet/unused-parameter.h \ + > $@-t && \ + mv $@-t $@ +MOSTLYCLEANFILES += unused-parameter.h unused-parameter.h-t + +UNUSED_PARAMETER_H=unused-parameter.h + +Include: + +License: +LGPLv2+ + +Maintainer: +Bruno Haible
--- a/modules/unistr/base +++ b/modules/unistr/base @@ -7,7 +7,7 @@ Depends-on: unitypes -unused-parameter +snippet/unused-parameter stdbool inline
deleted file mode 100644 --- a/modules/unused-parameter +++ /dev/null @@ -1,40 +0,0 @@ -Description: -A C macro for declaring that specific function parameters are not used. - -Applicability: -all - -Files: -build-aux/unused-parameter.h - -Depends-on: - -configure.ac: - -Makefile.am: -# The BUILT_SOURCES created by this Makefile snippet are not used via #include -# statements but through direct file reference. Therefore this snippet must be -# present in all Makefile.am that need it. This is ensured by the applicability -# 'all' defined above. - -BUILT_SOURCES += unused-parameter.h -# The unused-parameter.h that gets inserted into generated .h files is the same -# as build-aux/unused-parameter.h, except that it has the copyright header cut -# off. -unused-parameter.h: $(top_srcdir)/build-aux/unused-parameter.h - $(AM_V_GEN)rm -f $@-t $@ && \ - sed -n -e '/GL_UNUSED_PARAMETER/,$$p' \ - < $(top_srcdir)/build-aux/unused-parameter.h \ - > $@-t && \ - mv $@-t $@ -MOSTLYCLEANFILES += unused-parameter.h unused-parameter.h-t - -UNUSED_PARAMETER_H=unused-parameter.h - -Include: - -License: -LGPLv2+ - -Maintainer: -Bruno Haible