use crate::lower::wgsl::Error;
#[inline]
pub(crate) fn axis_letter(axis: u8) -> Result<char, Error> {
match axis {
0 => Ok('x'),
1 => Ok('y'),
2 => Ok('z'),
_ => Err(Error::lowering(format!(
"invocation axis {axis} is out of range. Fix: use axis 0, 1, or 2."
))),
}
}