-
-
Notifications
You must be signed in to change notification settings - Fork 732
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
Update bitWrite.adoc #885
base: master
Are you sure you want to change the base?
Update bitWrite.adoc #885
Conversation
bitWrite() function does return the updated value.
@@ -59,6 +59,7 @@ void setup() { | |||
Serial.println(x, BIN); // 10000000 | |||
bitWrite(x, 0, 1); // write 1 to the least significant bit of x | |||
Serial.println(x, BIN); // 10000001 | |||
Serial.println(bitWrite(x, 1, 1), BIN); // 10000011 |
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.
Serial.println(bitWrite(x, 1, 1), BIN); // 10000011 |
The example is meant to be a demonstration of the basic usage of the function. Even though it is indisputable that the "return" of the macro must be documented correctly, I don't think it needs to be demonstrated since this is not a common use pattern for bitWrite
.
If "it is indisputable that the "return" of the macro must be documented
correctly" then document it correctly. I bring this to your attention as
there are similar functions with this usage documented. Consistency is a
hallmark of good documentation.
Howard
|
Clearly we are in agreement on this subject, so there is no need to discuss it further. Let's focus on the specifics of my review so we can make progress in that direction. |
The specifics of your review were not very clear. However, if the "Returns"
section of the documentation is updated from "Nothing" to indicate that
there is in fact a return from this function, then that's all I'm looking
for..
|
@HowardWParr if you agree with the change I requested during my review, then make that change. If you disagree with the change I requested, then provide a clear explanation of why you disagree. I notice that you are replying via email. Please come here to the pull request page on GitHub so that you can be sure to see the actual suggestion I made. The pull request is at this URL: |
The bitWrite() function does return the updated value.