Skip to content

Commit 38422ef

Browse files
committed
Add NEWS.md entry for getindex(::AbstractString, ::AbstractVector) signature tightening (JuliaLang#20248).
1 parent 1129de3 commit 38422ef

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

NEWS.md

+9
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,14 @@ This section lists changes that do not have deprecation warnings.
211211
212212
* The `count` function no longer sums non-boolean values ([#20404])
213213
214+
* The generic `getindex(::AbstractString, ::AbstractVector)` method's signature has been
215+
tightened to `getindex(::AbstractString, ::AbstractVector{<:Integer})`. Consequently,
216+
indexing into `AbstractString`s with non-`AbstractVector{<:Integer}` `AbstractVector`s
217+
now throws a `MethodError` in the absence of an appropriate specialization.
218+
(Previously such cases failed less explicitly with the exception of
219+
`AbstractVector{Bool}`, which now throws an `ArgumentError` noting that
220+
logical indexing into strings is not supported.) ([#20248])
221+
214222
* Bessel, Hankel, Airy, error, Dawson, eta, zeta, digamma, inverse digamma,
215223
trigamma, and polygamma special functions have been moved from Base to
216224
the
@@ -501,6 +509,7 @@ Deprecated or removed
501509
[#20079]: https://github.com/JuliaLang/julia/issues/20079
502510
[#20164]: https://github.com/JuliaLang/julia/issues/20164
503511
[#20228]: https://github.com/JuliaLang/julia/issues/20228
512+
[#20248]: https://github.com/JuliaLang/julia/issues/20248
504513
[#20249]: https://github.com/JuliaLang/julia/issues/20249
505514
[#20268]: https://github.com/JuliaLang/julia/issues/20268
506515
[#20321]: https://github.com/JuliaLang/julia/issues/20321

0 commit comments

Comments
 (0)