2013
DOI: 10.1007/978-3-642-39718-9_12
|View full text |Cite
|
Sign up to set email alerts
|

Preemptive Type Checking in Dynamically Typed Languages

Abstract: Abstract. We describe a type system that identifies potential type errors in dynamically typed languages like Python. The system uses a flow-sensitive static analysis on bytecodes to compute, for every variable and program point, overapproximations of the variable's present and future use types. If the future use types are not subsumed by the present types, the further program execution may raise a type error, and a narrowing assertion is inserted; if future use and present types are disjoint, it will raise a … Show more

Help me understand this report

Search citation statements

Order By: Relevance

Paper Sections

Select...
4
1

Citation Types

0
6
0

Year Published

2014
2014
2019
2019

Publication Types

Select...
3
2

Relationship

1
4

Authors

Journals

citations
Cited by 7 publications
(6 citation statements)
references
References 20 publications
(18 reference statements)
0
6
0
Order By: Relevance
“…This paper is a revised and extended version of an earlier conference contribution that appeared in the proceedings of ICTAC 2013 [6]. The main differences are that we now give full formal proofs for all theorems in Section 3 and Section 4.…”
Section: Implementation and Evaluationmentioning
confidence: 99%
“…This paper is a revised and extended version of an earlier conference contribution that appeared in the proceedings of ICTAC 2013 [6]. The main differences are that we now give full formal proofs for all theorems in Section 3 and Section 4.…”
Section: Implementation and Evaluationmentioning
confidence: 99%
“…Since by definition, dynamic languages lack a built-in static typing discipline, much of the static verification work focuses on either retrofitting rich typing or specification disciplines [11,12,21] or applying whole-program flow analysis for inferring and checking type properties (e.g., for JavaScript [5,27,28] or for Ruby [1]). Researchers have also used static type inference to instrument dynamic programs with assertions that fail preemptively [23]; while similar in spirit to OVV, such approaches are still phasic, since type analysis occurs only once, before program execution begins.…”
Section: Related Workmentioning
confidence: 99%
“…It computes the present type of a variable (value assigned to it) and its future types (values that may be assigned later in the execution of the program). With this type information, dynamic type checks are inserted at strategic points of the original program . These type checks do not change the semantics of programs that do not raise type errors.…”
Section: Related Workmentioning
confidence: 99%
“…The objective of the inserted type checks is preempting all type errors at the earliest possible point for which a type error is inevitable, opposite to the typical runtime error produced at the point that a value of an incorrect type is used. Grech provided an implementation of preemptive type checking for Python .…”
Section: Related Workmentioning
confidence: 99%
See 1 more Smart Citation