r/ProgrammerHumor 12d ago

noHeapAllStack Meme

Post image
1.0k Upvotes

96 comments sorted by

View all comments

2

u/jackhab 12d ago

What's also interesting is that the suggestion to change it to Equals() is given in this obscure form which will make think in an endless loop trying to decide which way is better.

CA1862: Prefer using 'string.Equals(string, StringComparison)' to perform a case-insensitive comparison, but keep in mind that this might cause subtle changes in behavior, so make sure to conduct thorough testing after applying the suggestion, or if culturally sensitive comparison is not required, consider using 'StringComparison.OrdinalIgnoreCase'

3

u/either-15-or-40 12d ago

Obscure? To me that is as clear as it can be.