Lune

OOPSLA2021Top-tier venue

Promises are made to be broken: migrating R to strict semantics

Aviral Goel, Jan Jecmen, Sebastián Krynski, Olivier Flückiger, Jan Vitek

Abstract

Function calls in the R language do not evaluate their arguments, these are passed to the callee as suspended computations and evaluated if needed. After 25 years of experience with the language, there are very few cases where programmers leverage delayed evaluation intentionally and laziness comes at a price in performance and complexity. This paper explores how to evolve the semantics of a lazy language towards strictness-by-default and laziness-on-demand. To provide a migration path, it is necessary to provide tooling for developers to migrate libraries without introducing errors. This paper reports on a dynamic analysis that infers strictness signatures for functions to capture both intentional and accidental laziness. Over 99% of the inferred signatures were correct when tested against clients of the libraries.

Ask Lune

Know where this paper stands in minutes, not an afternoon.

Lune can read the top-tier papers that cite it and the ones closest to it, and tells you what it claims, what came after and where it falls short, each point cited to the paper it comes from. No skimming, no AI slop.

Questions to start from

Lune can draw on

its abstract · related work

Get the answer

Free to start. No credit card required.

Related papers

  1. Designing types for R, empiricallyAlexi Turcotte, Aviral Goel, Filip Krikava, Jan VitekOOPSLA 2020 · 9 citations
  2. Statically Analyzing the Dataflow of R ProgramsFlorian Sihler, Matthias TichyOOPSLA 2025 · 3 citations
  3. What we eval in the shadows: a large-scale study of eval in R programsAviral Goel, Pierre Donat-Bouillud, Filip Krikava, Christoph M. Kirsch et al.OOPSLA 2021 · 3 citations
  4. Typing StrictnessDaniel Sainati, Joseph W. Cutler, Benjamin C. Pierce, Stephanie WeirichPOPL 2026
  5. Contextual dispatch for function specializationOlivier Flückiger, Guido Chari, Ming-Ho Yee, Jan Jecmen et al.OOPSLA 2020 · 31 citations
Dusk over the sea between two cliffs drawn in fine vertical lines