LinearAlgebra: Type-stability in broadcasting numbers over Bidiagonal (#54067)
This makes the following type-stable:
```julia
julia> B = Bidiagonal(rand(3), rand(2), :U);
julia> @inferred (B -> B .* 2)(B)
3×3 Bidiagonal{Float64, Vector{Float64}}:
0.3929 1.93165 ⋅
⋅ 1.61301 1.00202
⋅ ⋅ 1.96483
```
Similarly, for other operations involving a single `Bidiagonal` and
numbers. This is not type-stable on master, as the number of
`Bidiagonal` matrices in a broadcast operation is not tracked (even
though this is used in promoting the `uplo`). Since the `uplo` can't be
constant-propagated, we count this by introducing an additional flag in
the promotion mechanism, which is entirely determined by the types of
the terms in the broadcast operation.
---------
Co-authored-by: N5N3 <2642243996@qq.com>