-
-
Notifications
You must be signed in to change notification settings - Fork 22.8k
Specifiy return value in several store methods in FileAccess
#107938
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
Conversation
Helps with users cleaning up RETURN_VALUE_DISCARDED gdscript warnings in a jiffy. |
It's not a good idea to make a whole new line for this. The sentence should be merged with the first line. Although, since this is common information, it may be worth mentioning it once and for all in the leading description. |
FileAccess
Done. I couldn't find a suitable reference for adding this in the leading description of the method definitions. Let me know if this would make sense somewhere specific and I can include the following line in the description - On the other hand, I feel it would be consistent to return the |
A quick skim through the code tells me the |
Undelaying platform API is also quite inconsistent and in many cases not capable of specifying exact reason of failure. Also, there's not much difference for the user. If the file write operation fails, the only thing you can do is close the file, it's non-recoverable. |
So can this be merged then? |
Thanks! |
Could you squash your commits? See our PR Workflow for more details: |
Some of the store methods did not specify the nature of return bool value. Added it after referring to FileAccess.cpp method. Moved return statement to preceding paragraph Addressed comments: Moved return description to first line
Thanks and done, will keep this in mind for the next time |
Thanks! And congrats for your first merged Godot contribution 🎉 |
Some of the store methods did not specify the nature of return bool value. Added it after referring to FileAccess.cpp method.