Skip to content

Conversation

@sreichel
Copy link
Contributor

@sreichel sreichel commented May 13, 2020

  • 3k occurrences of count and 119 of sizeof
  • simplified count(x) > 0
  • simplified count(x) == 0
  • strict type compare to int

- 3k occurrences of "count" and 119 of "sizeof"
- simplified "count(x) > 0"
- simplified "count(x) == 0"
- strict type compare to int
@sreichel sreichel added the Cleanup: Code style Related to simple CS fixes. label May 13, 2020
@tmotyl
Copy link
Contributor

tmotyl commented May 14, 2020

The places where we check if array is empty should be changed to !empty(). But maybe tackle it in a separate change?

@sreichel
Copy link
Contributor Author

@tmotyl I'd prefer seperate ticket to make reviews easier.

spinsch
spinsch previously approved these changes May 14, 2020
Copy link
Contributor

@spinsch spinsch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me.

@sreichel sreichel requested a review from colinmollenhour May 15, 2020 02:30
@tmotyl
Copy link
Contributor

tmotyl commented May 15, 2020

created an issue about checking emptiness #981

tmotyl
tmotyl previously approved these changes May 15, 2020
@sreichel sreichel dismissed stale reviews from tmotyl and spinsch via d2a734a May 30, 2020 02:48
@colinmollenhour colinmollenhour merged commit 0a832c1 into OpenMage:1.9.4.x Jun 5, 2020
@sreichel sreichel deleted the cs/count-vs-sizeof branch June 5, 2020 21:51
@sreichel sreichel added this to the Release 19.4.4 milestone Jun 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Cleanup: Code style Related to simple CS fixes.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants