17,890 research outputs found
Trust, but Verify: Two-Phase Typing for Dynamic Languages
A key challenge when statically typing so-called dynamic languages is the
ubiquity of value-based overloading, where a given function can dynamically
reflect upon and behave according to the types of its arguments. Thus, to
establish basic types, the analysis must reason precisely about values, but in
the presence of higher-order functions and polymorphism, this reasoning itself
can require basic types. In this paper we address this chicken-and-egg problem
by introducing the framework of two-phased typing. The first "trust" phase
performs classical, i.e. flow-, path- and value-insensitive type checking to
assign basic types to various program expressions. When the check inevitably
runs into "errors" due to value-insensitivity, it wraps problematic expressions
with DEAD-casts, which explicate the trust obligations that must be discharged
by the second phase. The second phase uses refinement typing, a flow- and
path-sensitive analysis, that decorates the first phase's types with logical
predicates to track value relationships and thereby verify the casts and
establish other correctness properties for dynamically typed languages
On Variants of CM-triviality
We introduce a generalization of CM-triviality relative to a fixed invariant
collection of partial types, in analogy to the Canonical Base Property defined
by Pillay, Ziegler and Chatzidakis which generalizes one-basedness. We show
that, under this condition, a stable field is internal to the family, and a
group of finite Lascar rank has a normal nilpotent subgroup such that the
quotient is almost internal to the family
Row and Bounded Polymorphism via Disjoint Polymorphism
Polymorphism and subtyping are important features in mainstream OO languages. The most common way to integrate the two is via ?_{< :} style bounded quantification. A closely related mechanism is row polymorphism, which provides an alternative to subtyping, while still enabling many of the same applications. Yet another approach is to have type systems with intersection types and polymorphism. A recent addition to this design space are calculi with disjoint intersection types and disjoint polymorphism. With all these alternatives it is natural to wonder how they are related.
This paper provides an answer to this question. We show that disjoint polymorphism can recover forms of both row polymorphism and bounded polymorphism, while retaining key desirable properties, such as type-safety and decidability. Furthermore, we identify the extra power of disjoint polymorphism which enables additional features that cannot be easily encoded in calculi with row polymorphism or bounded quantification alone. Ultimately we expect that our work is useful to inform language designers about the expressive power of those common features, and to simplify implementations and metatheory of feature-rich languages with polymorphism and subtyping
Costello, C. and Freedland, M. (eds.), Migrants at Work: Immigration & Vulnerability in Labour Law
No abstract available
The decision problem for a three-sorted fragment of set theory with restricted quantification and finite enumerations
We solve the satisfiability problem for a three-sorted fragment of set theory
(denoted ), which admits a restricted form of quantification over
individual and set variables and the finite enumeration operator over individual variables, by showing that it
enjoys a small model property, i.e., any satisfiable formula of
has a finite model whose size depends solely on the length of
itself. Several set-theoretic constructs are expressible by
-formulae, such as some variants of the power set operator and the
unordered Cartesian product. In particular, concerning the unordered Cartesian
product, we show that when finite enumerations are used to represent the
construct, the resulting formula is exponentially shorter than the one that can
be constructed without resorting to such terms
- …