A meta-theory for big-step semantics

04/12/2021
by   Francesco Dagnino, et al.
0

It is well-known that big-step semantics is not able to distinguish stuck and non-terminating computations. This is a strong limitation as it makes very difficult to reason about properties involving infinite computations, such as type soundness, which cannot even be expressed. To face this problem, we develop a systematic study of big-step semantics: we introduce an abstract definition of what a big-step semantics is, we formalise the evaluation algorithm implicitly associated with any big-step semantics and we identify computations with executions of such an algorithm, thus recovering the distinction between stuckness an non-termination. Then, we define constructions yielding an extended version of a given arbitrary big-step semantics, where such a difference is made explicit. Building on such constructions, we describe a general proof technique to show that a predicate is sound, that is, prevents stuck computation, with respect to a big-step semantics. The extended semantics are exploited in the meta-theory, notably they are necessary to show that the proof technique works. However, they remain transparent when using the proof technique, since it consists in checking three conditions on the original rules only. We illustrate the technique by several examples, showing that it is applicable also in cases where subject reduction does not hold, hence the standard technique for small-step semantics cannot be used.

READ FULL TEXT

Please sign up or login with your details

Forgot password? Click here to reset