Operations on Type Parameters

Let’s ask ourselves a quick question: Given a type parameter T, what kind of operations can we carry out over it? Because the type parameter T can be substituted for anything, our generic code can’t deal with specifics of a certain type. Nevertheless, a few basic operations can be meaningfully defined.

Get C# 5.0 Unleashed now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.