I've noticed that if have a List<T>
(or a few other types) and I press .
then among the intellisense suggestions I get Length
If I select Length
then what's actually typed is Count
I can see why this would happen, there's no Length
property on a List<T>
and if I'm looking for it I probably want Count
. My question is, how does Visual Studio know to do this? I can't see anything in the List<T>
class or anywhere else that encodes Length
as an alias for Count
.
This is a ReSharper 10 feature.
It integrated the Postfix Templates plugin in this version, and this is one of the completions it supports (use the correct Length
or Count
property).
I'm excited to announce that this plugin is now integral part of ReSharper 10!
The project page states:
Length/Count code completion solves one of the most common mistypings when dealing with arrays or collections:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With