C# borrows the behavior of its +
operator from Java. If either operand to +
is a string, the +
operator will call String.Concat
, which accepts type Object
and concatenates the results of calling ToString
on every non-null object that's passed to it. The fact that null references are simply ignored is only a small part of the way in which the operands to String.Concat
aren't regarded as "strings" per se; a much more noticeable aspect of this behavior is that types which aren't strings have their ToString
method called, whether or not they would otherwise be implicitly convertible to string
.