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

Security and clarity improvements #341

Merged
merged 5 commits into from
Dec 16, 2024
Merged

Conversation

Bigfoot71
Copy link
Contributor

I mainly added static to member functions where applicable, as well as noexcept to move constructors.

I also added the explicit keyword where preferable, while avoiding it in cases where the intent was clearly to facilitate logical conversions.

Additionally, I added the [[nodiscard]] attribute where appropriate, given that I also noticed the use of [[maybe_unused]] and thus assumed that the addition would be acceptable. This can always be removed if needed.

I also adjusted some inclusion issues that could prevent compilation depending on the order in which the headers were included, without directly including raylib-cpp.hpp.

There is also the addition of a few missing const qualifiers.

Finally, I made a few adjustments to constructors, avoiding initialization in the constructor body via set() where possible.

@RobLoach
Copy link
Owner

Thanks a lot 👍

@RobLoach RobLoach merged commit 6e4a852 into RobLoach:master Dec 16, 2024
0 of 8 checks passed
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.

2 participants