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

[Merged by Bors] - Replace default method calls from Glam types with explicit const #1645

Closed
wants to merge 2 commits into from

Conversation

mockersf
Copy link
Member

@mockersf mockersf commented Mar 13, 2021

it's a followup of #1550

I think calling explicit methods/values instead of default makes the code easier to read: "what is Quat::default()" vs "Oh, it's Quat::IDENTITY"

Transform::identity() and GlobalTransform::identity() can also be consts and I replaced the calls to their default() impl with identity()

@alice-i-cecile alice-i-cecile added the C-Code-Quality A section of code that is hard to understand or change label Mar 13, 2021
@cart
Copy link
Member

cart commented Mar 13, 2021

Good calls all around. Thanks!

@cart
Copy link
Member

cart commented Mar 13, 2021

bors r+

bors bot pushed a commit that referenced this pull request Mar 13, 2021
…1645)

it's a followup of #1550 

I think calling explicit methods/values instead of default makes the code easier to read: "what is `Quat::default()`" vs "Oh, it's `Quat::IDENTITY`"

`Transform::identity()` and `GlobalTransform::identity()` can also be consts and I replaced the calls to their `default()` impl with `identity()`
@bors bors bot changed the title Replace default method calls from Glam types with explicit const [Merged by Bors] - Replace default method calls from Glam types with explicit const Mar 13, 2021
@bors bors bot closed this Mar 13, 2021
@mockersf mockersf deleted the glam-default branch April 27, 2021 23:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-Code-Quality A section of code that is hard to understand or change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants