Code inspection: Redundant 'object.ToString()' call

Last modified: 05 June 2024

This inspection reports redundant ToString() calls in two cases:

  • When you call it on an object of type String.

  • When you call it in an argument of a method that implicitly calls ToString() on the corresponding parameter.

In both cases, the ToString() call is redundant and can be safely removed to improve readability.