Closed
Description
Came up over here: #25515 (comment). I think we should consider adding something like:
promote_rule(::Type{Char}, ::Type{S}) where {S<:AbstractString} = S
convert(::Type{String}, c::Char) = string(c)
convert(::Type{S}, c::Char) where {S<:AbstractString} =
convert(S, convert(String, c))
Previously when Char <: Integer
this was considerably sketchier but that's not the case anymore.
Metadata
Metadata
Assignees
Labels
No labels