Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Gregory Nutt
What to do about lines of code like this: ... # define GPIO_CNF_INPULLDWN (2 << GPIO_CNF_SHIFT) /* Input pull-down */ # define GPIO_CNF_INPULLUP ((2 << GPIO_CNF_SHIFT) | GPIO_OUTPUT_SET) /* Input pull-up */ ... I would probably fix that like: # define

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Gregory Nutt
I created PR https://github.com/apache/incubator-nuttx/pull/1079 to eliminate any distinction between C source file and header files in reporting long lines.  Both are equally errors.

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Gregory Nutt
No, that was never a rule.  We did use -m so that we didn't have to do so much work.  But that was just cutting corners; we (meaning us individually) allowed a little slop in line length just because we didn't want to do the work.  There has never been a policy that said long lines were

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Gregory Nutt
The rule use to be: long lines were ok in arch header files. No, that was never a rule.  We did use -m so that we didn't have to do so much work.  But that was just cutting corners; we (meaning us individually) allowed a little slop in line length just because we didn't want to do the

RE: nxstyle warnings: Fail precheck?

2020-05-19 Thread David Sidrane
- From: Nathan Hartman [mailto:hartman.nat...@gmail.com] Sent: Tuesday, May 19, 2020 1:18 PM To: dev@nuttx.apache.org Subject: Re: nxstyle warnings: Fail precheck? On Tue, May 19, 2020 at 4:01 PM Gregory Nutt wrote: > > Are nxstyle warnings supposed to make precheck fail at GitHub PR? I >

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Gregory Nutt
arch/arm/src/stm32/stm32_gpio.h:131:79: warning: Wrong column position of comment right of code Yes, the comments to the right of the definitions must be vertically aligned.

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Nathan Hartman
On Tue, May 19, 2020 at 4:27 PM Gregory Nutt wrote: > > It does print "error" for some and "warnings" for others. So I thought > > there was a difference. >> > Yes, that was added. But I don't know what it means. I guess that some > stylistic violations are not as bad as others? None are

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Gregory Nutt
It does print "error" for some and "warnings" for others. So I thought there was a difference. Yes, that was added.  But I don't know what it means.  I guess that some stylistic violations are not as bad as others?  None are tolerated, at least not without some extenuating circumstance.

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Nathan Hartman
On Tue, May 19, 2020 at 4:01 PM Gregory Nutt wrote: > > Are nxstyle warnings supposed to make precheck fail at GitHub PR? I > > thought only errors constitute fails. > > In the build checks C warnings are also converted to warnings via > -Werror and any warnings in the builds will fail the check.

Re: nxstyle warnings: Fail precheck?

2020-05-19 Thread Gregory Nutt
Are nxstyle warnings supposed to make precheck fail at GitHub PR? I thought only errors constitute fails. In the build checks C warnings are also converted to warnings via -Werror and any warnings in the builds will fail the check. Don't know about nxstyle, but there really is no such