We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b7b5ccb commit 6719bf6Copy full SHA for 6719bf6
base/operators.jl
@@ -66,14 +66,19 @@ Supertype operator, equivalent to `T2 <: T1`.
66
(>:)(@nospecialize(a), @nospecialize(b)) = (b <: a)
67
68
"""
69
- supertype(T::DataType)
+ supertype(T::Union{DataType, UnionAll})
70
71
-Return the supertype of DataType `T`.
+Return the direct supertype of type `T`.
72
+`T` can be a [`DataType`](@ref) or a [`UnionAll`](@ref) type. Does not support
73
+type [`Union`](@ref)s. Also see info on [Types](@ref man-types).
74
75
# Examples
76
```jldoctest
77
julia> supertype(Int32)
78
Signed
79
+
80
+julia> supertype(Vector)
81
+DenseVector (alias for DenseArray{T, 1} where T)
82
```
83
84
supertype(T::DataType) = (@_total_meta; T.super)
0 commit comments