Make gray const

This commit is contained in:
Tangent 128 2019-03-09 17:05:10 -05:00
parent 766f421a31
commit ee48d96a02
1 changed files with 1 additions and 1 deletions

View File

@ -48,7 +48,7 @@ impl core::ops::Mul<u8> for Rgb
/// Construct an [Rgb] from a monochrome value.
#[inline]
pub fn gray(gray: u8) -> Rgb {
pub const fn gray(gray: u8) -> Rgb {
Rgb(gray, gray, gray)
}