Skip to content

Commit

Permalink
Rename _FLOAT_TYPES to CORE_FLOAT_TYPES
Browse files Browse the repository at this point in the history
Co-authored-by: Jameson Nash <[email protected]>
  • Loading branch information
xal-0 and vtjnash authored Jan 31, 2025
1 parent d604e8e commit cdbda7c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Compiler/src/tfuncs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2455,7 +2455,7 @@ const _SPECIAL_BUILTINS = Any[
]

# Types compatible with fpext/fptrunc
const _FLOAT_TYPES = Any[Core.BFloat16, Float16, Float32, Float64]
const CORE_FLOAT_TYPES = Union{Core.BFloat16, Float16, Float32, Float64}

function isdefined_effects(𝕃::AbstractLattice, argtypes::Vector{Any})
# consistent if the first arg is immutable
Expand Down Expand Up @@ -2873,7 +2873,7 @@ function intrinsic_exct(𝕃::AbstractLattice, f::IntrinsicFunction, argtypes::V

# fpext and fptrunc have further restrictions on the allowed types.
if f === Intrinsics.fpext &&
!(ty in _FLOAT_TYPES && xty in _FLOAT_TYPES && Core.sizeof(ty) > Core.sizeof(xty))
!(ty <: CORE_FLOAT_TYPES && xty <: CORE_FLOAT_TYPES && Core.sizeof(ty) > Core.sizeof(xty))
return ErrorException
end
if f === Intrinsics.fptrunc &&
Expand Down

0 comments on commit cdbda7c

Please sign in to comment.