You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The reason will be displayed to describe this comment to others. Learn more.
Maybe. `!!x` is a well-known way to do that.
On 12/4/2015 10:51 PM, Alexandr Akulich wrote:
Just to be said, |lockCounter != 0| also does the trick and is (may be)
more readable.
—
Reply to this email directly or view it on GitHub
30d1f85#commitcomment-14795476.
The reason will be displayed to describe this comment to others. Learn more.
I don't mind if we stick with `x!=0` style.
On 12/4/2015 11:19 PM, Alexandr Akulich wrote:
Don't you think that |x != 0| is, say, five times more known and
popular, than |!!x|?
I saw |!!| only in expressions such as
|features_count = !!first_feature_things_count +
!!degree_of_the_second_feature + !!third_feature_objects_count|.
As usual, we all have habits, which rule on readability.
—
Reply to this email directly or view it on GitHub
30d1f85#commitcomment-14796073.
30d1f85
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to be said,
lockCounter != 0
also does the trick and is (may be) more readable.30d1f85
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
30d1f85
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't you agree that
x != 0
is, say, five times more known and popular, than!!x
?I saw
!!
only in expressions such asfeatures_count = !!first_feature_things_count + !!degree_of_the_second_feature + !!third_feature_object_count
.As usual, we all have habits, which rule on readability.
30d1f85
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.