New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New check: only one break or continue statement should be inside cycle body #374

Closed
sabaka opened this Issue Sep 13, 2015 · 5 comments

Comments

Projects
None yet
3 participants
@sabaka
Member

sabaka commented Sep 13, 2015

Restricting the number of break and continue statements in a loop is done in the interest of good structured programming.

One break and continue statement is acceptable in a loop, since it facilitates optimal coding. If there is more than one, the code should be refactored to increase readability.

inspired by: http://nemo.sonarqube.org/coding_rules#languages=java|q=one%20break

that rule already enforced over Checkstyle codebase.

@romani romani added the easy label Sep 13, 2015

@yaziza

This comment has been minimized.

Show comment
Hide comment
@yaziza

yaziza Dec 19, 2015

Member

Hi, i wanna contribute to the project and i think this issue can be a good starting as it s labeled easy.

Can you please give some hint where to start ?
Thank you !

Member

yaziza commented Dec 19, 2015

Hi, i wanna contribute to the project and i think this issue can be a good starting as it s labeled easy.

Can you please give some hint where to start ?
Thank you !

@romani

This comment has been minimized.

Show comment
Hide comment

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Dec 20, 2015

Issue #374: New check: only one break or continue statement should be…
… inside cycle body

Signed-off-by: Yasser Aziza <yasser.aziza@gmail.com>

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Dec 22, 2015

Issue #374: New check: only one break or continue statement should be…
… inside cycle body

Signed-off-by: Yasser Aziza <yasser.aziza@gmail.com>
@yaziza

This comment has been minimized.

Show comment
Hide comment
@yaziza

yaziza Dec 22, 2015

Member

Hi, i have started working on this issue, i will fix all checkstyle violations and write unit tests on the next few days. Feedback highly appreciated :)

Member

yaziza commented Dec 22, 2015

Hi, i have started working on this issue, i will fix all checkstyle violations and write unit tests on the next few days. Feedback highly appreciated :)

@romani

This comment has been minimized.

Show comment
Hide comment
@romani

romani Dec 22, 2015

Member

please finish with checkstyle violations first and then share a link for review.

Member

romani commented Dec 22, 2015

please finish with checkstyle violations first and then share a link for review.

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Dec 25, 2015

Issue #374: New check: only one break or continue statement should be…
… inside cycle body

Signed-off-by: Yasser Aziza <yasser.aziza@gmail.com>

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Dec 26, 2015

Issue #374: New check: only one break or continue statement should be…
… inside cycle body

Signed-off-by: Yasser Aziza <yasser.aziza@gmail.com>

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Dec 27, 2015

Issue #374: New check: only one break or continue statement should be…
… inside cycle body

Signed-off-by: Yasser Aziza <yasser.aziza@gmail.com>

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Dec 31, 2015

Issue #374: New check: only one break or continue statement should be…
… inside cycle body

Signed-off-by: Yasser Aziza <yasser.aziza@gmail.com>

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Jan 6, 2016

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Jan 11, 2016

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Jan 11, 2016

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Jan 11, 2016

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Jan 17, 2016

yaziza added a commit to yaziza/sevntu.checkstyle that referenced this issue Jan 17, 2016

romani added a commit that referenced this issue Jan 17, 2016

@romani romani added this to the 1.18 milestone Jan 17, 2016

@romani

This comment has been minimized.

Show comment
Hide comment
@romani

romani Jan 17, 2016

Member

merged.

Member

romani commented Jan 17, 2016

merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment