-
-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Make Size::new
const
#6594
Labels
A-UI
Graphical user interfaces, styles, layouts, and widgets
C-Usability
A targeted quality-of-life change that makes Bevy easier to use
D-Trivial
Nice and easy! A great choice to get started with Bevy
Comments
In general, we should be making methods like this const wherever possible. If we're unlikely to change it in the future to make it non-const, and it can be const, it should be const IMO. |
taiyoungjang
pushed a commit
to taiyoungjang/bevy
that referenced
this issue
Dec 15, 2022
) # Objective Fixes bevyengine#6594 ## Solution - `New` function for `Size` is now a `const` function :) ## Changelog - `New` function for `Size` is now a `const` function ## Migration Guide - Nothing has been changed
alradish
pushed a commit
to alradish/bevy
that referenced
this issue
Jan 22, 2023
) # Objective Fixes bevyengine#6594 ## Solution - `New` function for `Size` is now a `const` function :) ## Changelog - `New` function for `Size` is now a `const` function ## Migration Guide - Nothing has been changed
ItsDoot
pushed a commit
to ItsDoot/bevy
that referenced
this issue
Feb 1, 2023
) # Objective Fixes bevyengine#6594 ## Solution - `New` function for `Size` is now a `const` function :) ## Changelog - `New` function for `Size` is now a `const` function ## Migration Guide - Nothing has been changed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-UI
Graphical user interfaces, styles, layouts, and widgets
C-Usability
A targeted quality-of-life change that makes Bevy easier to use
D-Trivial
Nice and easy! A great choice to get started with Bevy
What problem does this solve or what need does it fill?
It is often useful to implement a
const
Size
for a widget. But, one cannot useSize::new
to define thisconst
...What solution would you like?
Make
Size::new
const.The text was updated successfully, but these errors were encountered: