nvdimm.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [ndctl PATCH] ndctl: warn on variables declared after statement
@ 2018-05-11 17:47 Dan Williams
  2018-05-11 18:02 ` Verma, Vishal L
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Williams @ 2018-05-11 17:47 UTC (permalink / raw)
  To: vishal.l.verma; +Cc: linux-nvdimm

Similar to the kernel, require all variables to be declared before
statements.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
---
 configure.ac |    1 +
 1 file changed, 1 insertion(+)

diff --git a/configure.ac b/configure.ac
index 6dbfcee88f7d..da56c413bffd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -148,6 +148,7 @@ my_CFLAGS="\
 -Wstrict-prototypes \
 -Wtype-limits \
 -Wmaybe-uninitialized \
+-Wdeclaration-after-statement \
 -Wunused-result \
 -D_FORTIFY_SOURCE=2
 "

_______________________________________________
Linux-nvdimm mailing list
Linux-nvdimm@lists.01.org
https://lists.01.org/mailman/listinfo/linux-nvdimm

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [ndctl PATCH] ndctl: warn on variables declared after statement
  2018-05-11 17:47 [ndctl PATCH] ndctl: warn on variables declared after statement Dan Williams
@ 2018-05-11 18:02 ` Verma, Vishal L
  0 siblings, 0 replies; 2+ messages in thread
From: Verma, Vishal L @ 2018-05-11 18:02 UTC (permalink / raw)
  To: Williams, Dan J; +Cc: linux-nvdimm

On Fri, 2018-05-11 at 10:47 -0700, Dan Williams wrote:
> Similar to the kernel, require all variables to be declared before
> statements.
> 
> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
> ---
>  configure.ac |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/configure.ac b/configure.ac
> index 6dbfcee88f7d..da56c413bffd 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -148,6 +148,7 @@ my_CFLAGS="\
>  -Wstrict-prototypes \
>  -Wtype-limits \
>  -Wmaybe-uninitialized \
> +-Wdeclaration-after-statement \
>  -Wunused-result \
>  -D_FORTIFY_SOURCE=2
>  "
> 

Thanks Dan, applied.
_______________________________________________
Linux-nvdimm mailing list
Linux-nvdimm@lists.01.org
https://lists.01.org/mailman/listinfo/linux-nvdimm

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-05-11 18:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-11 17:47 [ndctl PATCH] ndctl: warn on variables declared after statement Dan Williams
2018-05-11 18:02 ` Verma, Vishal L

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).