Safely expand SequencedCollection getFirst/Last
to also convert lists returned from method calls
#483
Labels
getFirst/Last
to also convert lists returned from method calls
#483
The recipe at https://docs.openrewrite.org/recipes/java/migrate/util/sequencedcollection
can recognize a match where a simple index value is used
but it misses code where the size of the collection being operated on is given (which an Intellij inspection will convert) such as
or even where a constant is used, such as
Calculating the index based on a constant value may be asking too much.
The text was updated successfully, but these errors were encountered: