Spelling suggestions: "subject:"constrained generics"" "subject:"constrained enterics""
1 |
Improving support for generic programming in C# with associated types and constraint propagationSrinivasa Raghavan, Aravind 15 May 2009 (has links)
Generics has recently been adopted to many mainstream object oriented languages,
such as C# and Java. As a particular design choice, generics in C# and Java
use a sub-typing relation to constraint type parameters. Failing to encapsulate type
parameters within generic interfaces and inability to encapsulate type constraints as
part of an interface definition have been identified as deficiencies in the way this design
choice has been implemented in these languages. These deficiencies can lead to
verbose and redundant code. In particular, they have been reported to affect the
development of highly generic libraries. To address these issues, extending object
oriented interfaces and sub-typing with associated types and constraint propagation
has been proposed and studied in an idealized small-scale formal setting. This thesis
builds on this previous work and provides a design and implementation of the
extensions in full C#. We also present a proof of soundness of the Featherweight
Generic Java (FGJ) formalism extended with interfaces. This property was assumed
in a proof of type safety of associated types and constraint propagation, but no proof
for the property was provided.
|
Page generated in 0.0835 seconds