Coeffects for Sharing and Mutation

09/15/2022
by   Riccardo Bianchini, et al.
0

In type-and-coeffect systems, contexts are enriched by coeffects modeling how they are actually used, typically through annotations on single variables. Coeffects are computed bottom-up, combining, for each term, the coeffects of its subterms, through a fixed set of algebraic operators. We show that this principled approach can be adopted to track sharing in the imperative paradigm, that is, links among variables possibly introduced by the execution. This provides a significant example of non-structural coeffects, which cannot be computed by-variable, since the way a given variable is used can affect the coeffects of other variables. To illustrate the effectiveness of the approach, we enhance the type system tracking sharing to model a sophisticated set of features related to uniqueness and immutability. Thanks to the coeffect-based approach, we can express such features in a simple way and prove related properties with standard techniques.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
03/15/2018

Tracing sharing in an imperative pure calculus

We introduce a type and effect system, for an imperative object calculus...
research
09/11/2023

Latte: Lightweight Aliasing Tracking for Java

Many existing systems track aliasing and uniqueness, each with their own...
research
03/15/2018

Tracing sharing in an imperative pure calculus (Extended Version)

We introduce a type and effect system, for an imperative object calculus...
research
06/23/2021

Native Implementation of Mutable Value Semantics

Unrestricted mutation of shared state is a source of many well-known pro...
research
10/08/2022

A Structural Equation Modeling Approach to Understand User's Perceptions of Acceptance of Ride-Sharing Services in Dhaka City

This research aims at building a multivariate statistical model for asse...
research
04/24/2018

Classifying variable-structures: a general framework

In this work, we unify recent variable-clustering techniques within a co...
research
05/05/2023

On the use of ordered factors as explanatory variables

Consider a regression or some regression-type model for a certain respon...

Please sign up or login with your details

Forgot password? Click here to reset