You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var list = new List<int>() {...}
var last = list.Last();
would be refactored to
var list = new List<int>() {...}
var last = list[list.Count - 1];
it would be good to have a different fix :
var list = new List<int>() {...}
var last = list[^1];
The text was updated successfully, but these errors were encountered:
fforjan
changed the title
OptimizeLinqUsageFixer.UseIndexerLast code fix to use IndexRange (or at least propose both options ?)
OptimizeLinqUsageFixer.UseIndexerLast code fix to use from the end Index (or at least propose both options ?)
Jun 12, 2024
Following code :
would be refactored to
it would be good to have a different fix :
The text was updated successfully, but these errors were encountered: