File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -660,6 +660,7 @@ function promote_to_concrete(vs; tofloat = true, use_union = true)
660660 I = Int8
661661 has_int = false
662662 has_array = false
663+ has_bool = false
663664 array_T = nothing
664665 for v in vs
665666 if v isa AbstractArray
@@ -672,6 +673,9 @@ function promote_to_concrete(vs; tofloat = true, use_union = true)
672673 has_int = true
673674 I = promote_type (I, E)
674675 end
676+ if E <: Bool
677+ has_bool = true
678+ end
675679 end
676680 if tofloat && ! has_array
677681 C = float (C)
@@ -682,6 +686,9 @@ function promote_to_concrete(vs; tofloat = true, use_union = true)
682686 if has_int
683687 C = Union{C, I}
684688 end
689+ if has_bool
690+ C = Union{C, Bool}
691+ end
685692 return copyto! (similar (vs, C), vs)
686693 end
687694 convert .(C, vs)
You can’t perform that action at this time.
0 commit comments