Skip to content

Commit

Permalink
Merge pull request #433 from marcandre/array_int
Browse files Browse the repository at this point in the history
Array: fix `int` vs `Integer`
  • Loading branch information
soutaro authored Oct 19, 2020
2 parents 0cb8768 + b3a130e commit 3bb2d32
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions stdlib/builtin/array.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -887,7 +887,7 @@ class Array[unchecked out Elem] < Object
#
def fetch: (int index) -> Elem
| [T] (int index, T default) -> (Elem | T)
| [T] (::Integer index) { (::Integer index) -> T } -> (Elem | T)
| [T] (int index) { (int index) -> T } -> (Elem | T)

# The first three forms set the selected elements of `self` (which may be the
# entire array) to `obj`.
Expand Down Expand Up @@ -1352,8 +1352,8 @@ class Array[unchecked out Elem] < Object
# a.permutation(0).to_a #=> [[]] # one permutation of length 0
# a.permutation(4).to_a #=> [] # no permutations of length 4
#
def permutation: (?::Integer n) -> ::Enumerator[::Array[Elem], ::Array[Elem]]
| (?::Integer n) { (::Array[Elem] p) -> void } -> ::Array[Elem]
def permutation: (?int n) -> ::Enumerator[::Array[Elem], ::Array[Elem]]
| (?int n) { (::Array[Elem] p) -> void } -> ::Array[Elem]

# Removes the last element from `self` and returns it, or `nil` if the array is
# empty.
Expand Down

0 comments on commit 3bb2d32

Please sign in to comment.