List Info

Thread: suggestion - add -Wdeclaration-after-statement to AST_DEVMODE builds




suggestion - add -Wdeclaration-after-statement to AST_DEVMODE builds
country flaguser name
United States
2007-06-24 16:10:04
I'd like to suggest the following patch to the top level
asterisk Makefile:

Index: Makefile
============================================================
=======
--- Makefile    (revision 71337)
+++ Makefile    (working copy)
 -193,6
+193,6 
 ASTCFLAGS+=-include
$(ASTTOPDIR)/include/asterisk/autoconfig.h
 
 ifeq ($(AST_DEVMODE),yes)
-  ASTCFLAGS+=-Werror -Wunused -Wundef
+  ASTCFLAGS+=-Werror -Wunused -Wundef 
-Wdeclaration-after-statement
 endif

so that declarations in the middle of a block are detected
in AST_DEVMODE builds. There are a few instances of it
(chan_sip.c, chan_skinny.c, app_minivm.c, app_sms.c amongh
the
modules i can compile myself) and this change helps
catching
them earlier.

objections ? this is only for trunk and 1.4

	cheers
	luigi

_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.c
om--

asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev

Re: suggestion - add -Wdeclaration-after-statement to AST_DEVMODE builds
country flaguser name
United States
2007-06-25 08:52:26
Luigi Rizzo wrote:
> I'd like to suggest the following patch to the top
level asterisk Makefile:
> 
> Index: Makefile
>
============================================================
=======
> --- Makefile    (revision 71337)
> +++ Makefile    (working copy)
>  -193,6 +193,6 
>  ASTCFLAGS+=-include
$(ASTTOPDIR)/include/asterisk/autoconfig.h
>  
>  ifeq ($(AST_DEVMODE),yes)
> -  ASTCFLAGS+=-Werror -Wunused -Wundef
> +  ASTCFLAGS+=-Werror -Wunused -Wundef 
-Wdeclaration-after-statement
>  endif

That change is fine with me.

-- 
Russell Bryant
Software Engineer
Digium, Inc.

_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.c
om--

asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev

Re: suggestion - add -Wdeclaration-after-statement to AST_DEVMODE builds
country flaguser name
United States
2007-06-25 15:37:59
Russell Bryant wrote:

> That change is fine with me.

Me too.

-- 
Kevin P. Fleming
Director of Software Technologies
Digium, Inc. - "The Genuine Asterisk Experience"
(TM)

_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.c
om--

asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )