Skip to content

Commit 96e4301

Browse files
fredrikekreKristofferC
authored andcommitted
Reference all the numbers (#22107)
* references for Rational * references for Complex * references for Number * references to Real * references for AbstractFloat * references for Integer * references for Signed * references for Unsigned * references to Bool * references for Float16 * references for Float32 * references for Float64 * references for Int8 * references for UInt8 * references for Int16 * references for UInt16 * references for Int32 * references for UInt32 * references for Int64 * references for UInt64 * references for Int128 * references for UInt128 * references for BigInt * references for BigFloat
1 parent 06521f1 commit 96e4301

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+343
-312
lines changed

base/Enums.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,9 @@ julia> f(apple)
4545
"I'm a Fruit with value: 1"
4646
```
4747
48-
`BaseType`, which defaults to `Int32`, must be a primitive subtype of Integer. Member values can be converted between
49-
the enum type and `BaseType`. `read` and `write` perform these conversions automatically.
48+
`BaseType`, which defaults to [`Int32`](@ref), must be a primitive subtype of `Integer`.
49+
Member values can be converted between the enum type and `BaseType`. `read` and `write`
50+
perform these conversions automatically.
5051
"""
5152
macro enum(T,syms...)
5253
if isempty(syms)

base/abstractarray.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -503,7 +503,7 @@ julia> similar(trues(10,10), 2)
503503
false
504504
```
505505
506-
Since `BitArray`s can only store elements of type `Bool`, however, if you request a
506+
Since `BitArray`s can only store elements of type [`Bool`](@ref), however, if you request a
507507
different element type it will create a regular `Array` instead:
508508
509509
```julia-repl

base/array.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ end
266266
eye([T::Type=Float64,] m::Integer, n::Integer)
267267
268268
`m`-by-`n` identity matrix.
269-
The default element type is `Float64`.
269+
The default element type is [`Float64`](@ref).
270270
"""
271271
function eye(::Type{T}, m::Integer, n::Integer) where T
272272
a = zeros(T,m,n)
@@ -287,7 +287,7 @@ eye(::Type{T}, n::Integer) where {T} = eye(T, n, n)
287287
eye([T::Type=Float64,] n::Integer)
288288
289289
`n`-by-`n` identity matrix.
290-
The default element type is `Float64`.
290+
The default element type is [`Float64`](@ref).
291291
"""
292292
eye(n::Integer) = eye(Float64, n)
293293

base/c.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ Culong
4545
"""
4646
Cwchar_t
4747
48-
Equivalent to the native `wchar_t` c-type (`Int32`).
48+
Equivalent to the native `wchar_t` c-type ([`Int32`](@ref)).
4949
"""
5050
Cwchar_t
5151

base/ctypes.jl

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,39 +6,39 @@
66
"""
77
Cuchar
88
9-
Equivalent to the native `unsigned char` c-type (`UInt8`).
9+
Equivalent to the native `unsigned char` c-type ([`UInt8`](@ref)).
1010
"""
1111
const Cuchar = UInt8
1212

1313

1414
"""
1515
Cshort
1616
17-
Equivalent to the native `signed short` c-type (`Int16`).
17+
Equivalent to the native `signed short` c-type ([`Int16`](@ref)).
1818
"""
1919
const Cshort = Int16
2020

2121

2222
"""
2323
Cushort
2424
25-
Equivalent to the native `unsigned short` c-type (`UInt16`).
25+
Equivalent to the native `unsigned short` c-type ([`UInt16`](@ref)).
2626
"""
2727
const Cushort = UInt16
2828

2929

3030
"""
3131
Cint
3232
33-
Equivalent to the native `signed int` c-type (`Int32`).
33+
Equivalent to the native `signed int` c-type ([`Int32`](@ref)).
3434
"""
3535
const Cint = Int32
3636

3737

3838
"""
3939
Cuint
4040
41-
Equivalent to the native `unsigned int` c-type (`UInt32`).
41+
Equivalent to the native `unsigned int` c-type ([`UInt32`](@ref)).
4242
"""
4343
const Cuint = UInt32
4444

@@ -70,46 +70,46 @@ const Cssize_t = Int
7070
"""
7171
Cintmax_t
7272
73-
Equivalent to the native `intmax_t` c-type (`Int64`).
73+
Equivalent to the native `intmax_t` c-type ([`Int64`](@ref)).
7474
"""
7575
const Cintmax_t = Int64
7676

7777

7878
"""
7979
Cuintmax_t
8080
81-
Equivalent to the native `uintmax_t` c-type (`UInt64`).
81+
Equivalent to the native `uintmax_t` c-type ([`UInt64`](@ref)).
8282
"""
8383
const Cuintmax_t = UInt64
8484

8585

8686
"""
8787
Clonglong
8888
89-
Equivalent to the native `signed long long` c-type (`Int64`).
89+
Equivalent to the native `signed long long` c-type ([`Int64`](@ref)).
9090
"""
9191
const Clonglong = Int64
9292

9393

9494
"""
9595
Culonglong
9696
97-
Equivalent to the native `unsigned long long` c-type (`UInt64`).
97+
Equivalent to the native `unsigned long long` c-type ([`UInt64`](@ref)).
9898
"""
9999
const Culonglong = UInt64
100100

101101

102102
"""
103103
Cfloat
104104
105-
Equivalent to the native `float` c-type (`Float32`).
105+
Equivalent to the native `float` c-type ([`Float32`](@ref)).
106106
"""
107107
const Cfloat = Float32
108108

109109

110110
"""
111111
Cdouble
112112
113-
Equivalent to the native `double` c-type (`Float64`).
113+
Equivalent to the native `double` c-type ([`Float64`](@ref)).
114114
"""
115115
const Cdouble = Float64

base/dates/accessors.jl

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ for func in (:year, :month)
7474
@doc """
7575
$($name)(dt::TimeType) -> Int64
7676
77-
The $($name) of a `Date` or `DateTime` as an `Int64`.
77+
The $($name) of a `Date` or `DateTime` as an [`Int64`](@ref).
7878
""" $func(dt::TimeType)
7979
end
8080
end
@@ -83,9 +83,10 @@ end
8383
week(dt::TimeType) -> Int64
8484
8585
Return the [ISO week date](https://en.wikipedia.org/wiki/ISO_week_date) of a `Date` or
86-
`DateTime` as an `Int64`. Note that the first week of a year is the week that contains the
87-
first Thursday of the year which can result in dates prior to January 4th being in the last
88-
week of the previous year. For example `week(Date(2005,1,1))` is the 53rd week of 2004.
86+
`DateTime` as an [`Int64`](@ref). Note that the first week of a year is the week that
87+
contains the first Thursday of the year which can result in dates prior to January 4th
88+
being in the last week of the previous year. For example `week(Date(2005,1,1))` is the 53rd
89+
week of 2004.
8990
"""
9091
week(dt::TimeType)
9192

@@ -95,15 +96,15 @@ for func in (:day, :dayofmonth)
9596
@doc """
9697
$($name)(dt::TimeType) -> Int64
9798
98-
The day of month of a `Date` or `DateTime` as an `Int64`.
99+
The day of month of a `Date` or `DateTime` as an [`Int64`](@ref).
99100
""" $func(dt::TimeType)
100101
end
101102
end
102103

103104
"""
104105
hour(dt::DateTime) -> Int64
105106
106-
The hour of day of a `DateTime` as an `Int64`.
107+
The hour of day of a `DateTime` as an [`Int64`](@ref).
107108
"""
108109
hour(dt::DateTime)
109110

@@ -113,7 +114,7 @@ for func in (:minute, :second, :millisecond)
113114
@doc """
114115
$($name)(dt::DateTime) -> Int64
115116
116-
The $($name) of a `DateTime` as an `Int64`.
117+
The $($name) of a `DateTime` as an [`Int64`](@ref).
117118
""" $func(dt::DateTime)
118119
end
119120
end
@@ -137,7 +138,7 @@ for func in (:hour, :minute, :second, :millisecond, :microsecond, :nanosecond)
137138
@doc """
138139
$($name)(t::Time) -> Int64
139140
140-
The $($name) of a `Time` as an `Int64`.
141+
The $($name) of a `Time` as an [`Int64`](@ref).
141142
""" $func(t::Time)
142143
end
143144
end

base/dates/adjusters.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@ tonext(dt::TimeType, dow::Int; same::Bool=false) = adjust(ISDAYOFWEEK[dow], same
253253
tonext(func::Function, dt::TimeType; step=Day(1), limit=10000, same=false) -> TimeType
254254
255255
Adjusts `dt` by iterating at most `limit` iterations by `step` increments until `func`
256-
returns `true`. `func` must take a single `TimeType` argument and return a `Bool`. `same`
257-
allows `dt` to be considered in satisfying `func`.
256+
returns `true`. `func` must take a single `TimeType` argument and return a [`Bool`](@ref).
257+
`same` allows `dt` to be considered in satisfying `func`.
258258
"""
259259
function tonext(func::Function, dt::TimeType; step::Period=Day(1), negate=nothing, limit::Int=10000, same::Bool=false)
260260
func = deprecate_negate(:tonext, func, "func,dt", negate)
@@ -274,8 +274,8 @@ toprev(dt::TimeType, dow::Int; same::Bool=false) = adjust(ISDAYOFWEEK[dow], same
274274
toprev(func::Function, dt::TimeType; step=Day(-1), limit=10000, same=false) -> TimeType
275275
276276
Adjusts `dt` by iterating at most `limit` iterations by `step` increments until `func`
277-
returns `true`. `func` must take a single `TimeType` argument and return a `Bool`. `same`
278-
allows `dt` to be considered in satisfying `func`.
277+
returns `true`. `func` must take a single `TimeType` argument and return a [`Bool`](@ref).
278+
`same` allows `dt` to be considered in satisfying `func`.
279279
"""
280280
function toprev(func::Function, dt::TimeType; step::Period=Day(-1), negate=nothing, limit::Int=10000, same::Bool=false)
281281
func = deprecate_negate(:toprev, func, "func,dt", negate)

base/dates/conversions.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ end
5353
datetime2unix(dt::DateTime) -> Float64
5454
5555
Takes the given `DateTime` and returns the number of seconds
56-
since the unix epoch `1970-01-01T00:00:00` as a `Float64`.
56+
since the unix epoch `1970-01-01T00:00:00` as a [`Float64`](@ref).
5757
"""
5858
datetime2unix(dt::DateTime) = (value(dt) - UNIXEPOCH) / 1000.0
5959

@@ -116,6 +116,6 @@ end
116116
datetime2julian(dt::DateTime) -> Float64
117117
118118
Takes the given `DateTime` and returns the number of Julian calendar days since the julian
119-
epoch `-4713-11-24T12:00:00` as a `Float64`.
119+
epoch `-4713-11-24T12:00:00` as a [`Float64`](@ref).
120120
"""
121121
datetime2julian(dt::DateTime) = (value(dt) - JULIANEPOCH) / 86400000.0

base/dates/periods.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ for period in (:Year, :Month, :Week, :Day, :Hour, :Minute, :Second, :Millisecond
3333
$($period_str)(v)
3434
3535
Construct a `$($period_str)` object with the given `v` value. Input must be
36-
losslessly convertible to an `Int64`.
36+
losslessly convertible to an [`Int64`](@ref).
3737
""" $period(v)
3838
end
3939
end

base/dates/query.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ dayofyear(y, m, d) = MONTHDAYS[m] + d + (m > 2 && isleapyear(y))
101101
"""
102102
dayofweek(dt::TimeType) -> Int64
103103
104-
Returns the day of the week as an `Int64` with `1 = Monday, 2 = Tuesday, etc.`.
104+
Returns the day of the week as an [`Int64`](@ref) with `1 = Monday, 2 = Tuesday, etc.`.
105105
"""
106106
dayofweek(dt::TimeType) = dayofweek(days(dt))
107107

0 commit comments

Comments
 (0)