Update a f16/f128 FIXME to be more accurate

This commit is contained in:
Trevor Gross 2024-07-08 18:04:01 -04:00
parent 321eba5e8f
commit 96a791662a

View File

@ -563,7 +563,8 @@ fn lint_literal<'tcx>(
ty::Float(t) => {
let is_infinite = match lit.node {
ast::LitKind::Float(v, _) => match t {
// FIXME(f16_f128): add this check once we have library support
// FIXME(f16_f128): add this check once `is_infinite` is reliable (ABI
// issues resolved).
ty::FloatTy::F16 => Ok(false),
ty::FloatTy::F32 => v.as_str().parse().map(f32::is_infinite),
ty::FloatTy::F64 => v.as_str().parse().map(f64::is_infinite),