Skip to content

Commit 32ea4a6

Browse files
authored
Declare LinearAlgebra.AbstractTriangular to be public (#52246)
Since methods such as `mul!`, `(l/r)mul!` and `(l/r)div!` are defined for `AbstractTriangular`, having this be public allows easier disambiguation in packages. [Several packages](https://juliahub.com/ui/Search?q=AbstractTriangular&type=code) are already using it as if it's public, so it makes sense to support this. This would resolve the specific issue in https://discourse.julialang.org/t/methoderrors-suggest-fixes-that-may-depend-on-internal-bindings/106468
1 parent 092f60b commit 32ea4a6

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

src/LinearAlgebra.jl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,9 @@ export
161161
# Constants
162162
I
163163

164+
# not exported, but public names
165+
public AbstractTriangular
166+
164167
const BlasFloat = Union{Float64,Float32,ComplexF64,ComplexF32}
165168
const BlasReal = Union{Float64,Float32}
166169
const BlasComplex = Union{ComplexF64,ComplexF32}

src/triangular.jl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@
33
## Triangular
44

55
# could be renamed to Triangular when that name has been fully deprecated
6+
"""
7+
AbstractTriangular
8+
9+
Supertype of triangular matrix types such as [`LowerTriangular`](@ref), [`UpperTriangular`](@ref),
10+
[`UnitLowerTriangular`](@ref) and [`UnitUpperTriangular`](@ref).
11+
"""
612
abstract type AbstractTriangular{T} <: AbstractMatrix{T} end
713

814
# First loop through all methods that don't need special care for upper/lower and unit diagonal

0 commit comments

Comments
 (0)