Improving Type Error Messages For Generic Java

Stc
Date: 2008-04-24

Time: 12:00

Room: BBL room 471

Speaker: Nabil el Boustani

Title: Improving Type Error Messages for Generic Java (Thesis Defense)

Abstract

Generics, alternatively called parametric polymorphism, are a powerful programming concept that makes higher and cleaner abstractions possible, which helps developing reusable code. Java supports parametric polymorphism since its 1.5 release, where it was perceived as one of the great and most advanced features added to the language. However, adding parametric polymorphism to a language that is built on inclusion polymorphism can be confusing to a novice programmer, because the typing rules are suddenly different and, in the case of Java, quite complex. To help novice programmers get accustomed to the new typing rules, we describe a framework in this thesis that can be used by the type checking process to generate error messages that explain why a type error occurs and contain additional hints, which describe how to correct a type error or prevent new errors in future compilations. This framework only supports the type checking of generic method invocations, where the compiler must infer the type arguments of a method.