This paper addresses a frequently encountered problem related to type constraints in many contemporary strongly typed object-oriented languages. The problem is that type parameters are often more strongly constrained than is actually needed. As a consequence, reusability of the whole generic definition is limited even when those constraints are only for a portion of the operations it provides. A useful programming idiom to remedy this problem is proposed. It mitigates the problem by moving some of type constraints from the generic definitions to the clients. The only tool required to aid the idiom is the functional parameter.
Unfortunately, ACM prohibits us from displaying non-influential references for this paper.
To see the full reference list, please visit http://dl.acm.org/citation.cfm?id=261360.