Bug #85824 Add warn_unused_result to Dictionary_client methods
Submitted: 6 Apr 2017 7:32 Modified: 6 Apr 2017 22:13
Reporter: Jon Olav Hauglid Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Data Dictionary Severity:S3 (Non-critical)
Version:8.0.2 OS:Any
Assigned to: CPU Architecture:Any

[6 Apr 2017 7:32] Jon Olav Hauglid
Description:
We should add __attribute__((warn_unused_result)) to the Dictionary_client methods to make them harder to misuse.
This will give compilation warnings (GCC, Clang) if the API user ignores return values.

How to repeat:
Code inspection.
[6 Apr 2017 22:13] Daniel Price
Posted by developer:
 
Fixed as of the upcoming 8.0.2 release, and here's the changelog entry:

An attribute was added to data dictionary client method declarations to
generate compilation warnings when return values are ignored.