Skip to content

Commit

Permalink
Fix div docstring to describe division, after JuliaLang#33040
Browse files Browse the repository at this point in the history
It looks like in JuliaLang#33040 the `div` docstring was accidentally incorrectly copied from the `rem` docstring, so it currently describes the `rem` operation, not `div`.

This commit changes that docstring to correctly describe integer division with custom rounding.
  • Loading branch information
NHDaly committed Oct 28, 2019
1 parent 88c34fc commit e3f44d6
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions base/div.jl
Expand Up @@ -3,12 +3,11 @@
"""
div(x, y, r::RoundingMode=RoundToZero)
Compute the remainder of `x` after integer division by `y`, with the quotient rounded
according to the rounding mode `r`. In other words, the quantity
The quotient from Euclidean division. Computes x/y, rounded to an integer according
to the rounding mode `r`. In other words, the following quantity:
y*round(x/y,r)
round(x/y,r)
without any intermediate rounding.
See also: [`fld`](@ref), [`cld`](@ref) which are special cases of this function
Expand Down

0 comments on commit e3f44d6

Please sign in to comment.