pluggable-checkers-issta2008 - Practical Pluggable Types...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Practical Pluggable Types for Java Matthew M. Papi Mahmood Ali Telmo Luis Correa Jr. Jeff H. Perkins Michael D. Ernst MIT Computer Science and Artificial Intelligence Lab, Cambridge, MA, USA {mpapi,mali,telmo,jhp,mernst} Abstract This paper introduces the Checker Framework, which supports adding pluggable type systems to the Java language in a backward- compatible way. A type system designer defines type qualifiers and their semantics, and a compiler plug-in enforces the semantics. Programmers can write the type qualifiers in their programs and use the plug-in to detect or prevent errors. The Checker Framework is useful both to programmers who wish to write error-free code, and to type system designers who wish to evaluate and deploy their type systems. The Checker Framework includes new Java syntax for express- ing type qualifiers; declarative and procedural mechanisms for writ- ing type-checking rules; and support for flow-sensitive local type qualifier inference and for polymorphism over types and qualifiers. The Checker Framework is well-integrated with the Java language and toolset. We have evaluated the Checker Framework by writing 5 check- ers and running them on over 600K lines of existing code. The checkers found real errors, then confirmed the absence of further errors in the fixed code. The case studies also shed light on the type systems themselves. Categories and subject descriptors: D3.3 [Programming Lan- guages]: Language Constructs and Features data types and struc- tures ; F3.1 [Logics and Meanings of Programs]: Specifying and Verifying and Reasoning about Programs; D1.5 [Programming Tech- niques]: Object-oriented Programming General terms: Languages, Theory Keywords: annotation, bug finding, case study, compiler, flow- sensitivity, IGJ, immutable, intern, Java, javac, Javari, NonNull, pluggable type, polymorphism, readonly, type qualifier, type sys- tem, verification 1. Introduction A static type system helps programmers to detect and prevent errors. However, a languages built-in type system does not help to detect and prevent enough errors, because it cannot express cer- tain important invariants. A user-defined, or pluggable, type sys- tem enriches the built-in type system by expressing extra infor- mation about types via type qualifiers. Example qualifiers include nonnull , readonly , interned , and tainted . Pluggable types Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. To copy otherwise, to republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee....
View Full Document

This note was uploaded on 02/24/2012 for the course CSE 503 taught by Professor Davidnotikin during the Spring '11 term at University of Washington.

Page1 / 11

pluggable-checkers-issta2008 - Practical Pluggable Types...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online