Skip to content
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

Add a method to report library version from ApiHandle #579

Merged
merged 1 commit into from
Dec 7, 2023

Conversation

SergeyRyabinin
Copy link
Contributor

@SergeyRyabinin SergeyRyabinin commented Dec 7, 2023

Issue #, if available:
CRT-CPP package does not expose it's version.
Description of changes:
Add a method that will return the version declared at the build time.

update: update clang format

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

* Gets the version of the AWS-CRT-CPP library
* @return- CrtCppVersion representing the library version
*/
const CrtCppVersion &GetCrtVersion() const;
Copy link
Contributor

Choose a reason for hiding this comment

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

trivial: simpler/safer to just return by value const CrtCppVersion -> CrtCppVersion

Copy link
Contributor

Choose a reason for hiding this comment

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

trivial: GetCrtVersion() -> GetVersion()

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I thought about simple "GetVersion" but then remembered there is one OS manufacturer that defines GetVersion to a macro in their SDK headers :-).

include/aws/crt/Api.h Outdated Show resolved Hide resolved
@SergeyRyabinin SergeyRyabinin force-pushed the sr/reportVersion branch 3 times, most recently from 9399a44 to b0ed502 Compare December 7, 2023 19:53
@SergeyRyabinin SergeyRyabinin merged commit ddab824 into main Dec 7, 2023
55 checks passed
@SergeyRyabinin SergeyRyabinin deleted the sr/reportVersion branch December 7, 2023 21:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants