mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
[ruby/matrix] Replace "iff" with "whether" [doc]
iff means if and only if, but readers without that knowledge might assume this to be a spelling mistake. To me, this seems like exclusionary language that is unnecessary. Simply using "whether" when describing return values should suffice.
This commit is contained in:
parent
e34f51fe60
commit
871b4612b0
1 changed files with 5 additions and 5 deletions
|
@ -1016,7 +1016,7 @@ class Matrix
|
||||||
#++
|
#++
|
||||||
|
|
||||||
#
|
#
|
||||||
# Returns +true+ if and only if the two matrices contain equal elements.
|
# Returns whether the two matrices contain equal elements.
|
||||||
#
|
#
|
||||||
def ==(other)
|
def ==(other)
|
||||||
return false unless Matrix === other &&
|
return false unless Matrix === other &&
|
||||||
|
@ -2134,7 +2134,7 @@ class Vector
|
||||||
#++
|
#++
|
||||||
|
|
||||||
#
|
#
|
||||||
# Returns +true+ iff all of vectors are linearly independent.
|
# Returns whether all of vectors are linearly independent.
|
||||||
#
|
#
|
||||||
# Vector.independent?(Vector[1,0], Vector[0,1])
|
# Vector.independent?(Vector[1,0], Vector[0,1])
|
||||||
# # => true
|
# # => true
|
||||||
|
@ -2152,7 +2152,7 @@ class Vector
|
||||||
end
|
end
|
||||||
|
|
||||||
#
|
#
|
||||||
# Returns +true+ iff all of vectors are linearly independent.
|
# Returns whether all of vectors are linearly independent.
|
||||||
#
|
#
|
||||||
# Vector[1,0].independent?(Vector[0,1])
|
# Vector[1,0].independent?(Vector[0,1])
|
||||||
# # => true
|
# # => true
|
||||||
|
@ -2165,7 +2165,7 @@ class Vector
|
||||||
end
|
end
|
||||||
|
|
||||||
#
|
#
|
||||||
# Returns +true+ iff all elements are zero.
|
# Returns whether all elements are zero.
|
||||||
#
|
#
|
||||||
def zero?
|
def zero?
|
||||||
all?(&:zero?)
|
all?(&:zero?)
|
||||||
|
@ -2193,7 +2193,7 @@ class Vector
|
||||||
#++
|
#++
|
||||||
|
|
||||||
#
|
#
|
||||||
# Returns +true+ iff the two vectors have the same elements in the same order.
|
# Returns whether the two vectors have the same elements in the same order.
|
||||||
#
|
#
|
||||||
def ==(other)
|
def ==(other)
|
||||||
return false unless Vector === other
|
return false unless Vector === other
|
||||||
|
|
Loading…
Add table
Reference in a new issue