Please rotate your tablet to be horizontal.

You can dismiss this notice but please note that this experience has not been designed for mobile devices and so will be less than optimal

Back To Schedule

Val Wants To Be Your Friend

The design of a safe, fast, and simple programming language

10:30 - 11:30 Friday 16th September 2022 MDT Summit 2 & 3 / Online D
Intermediate
Advanced
Value Semantics

Val is a programming language based on two of the best ideas behind C++: generic programming and first-class value semantics. Unlike C++, however, Val is a safe-by-default programming language, meaning that many guarantees that are enforced by convention in C++ are proven by induction in Val.

Val follows strict mutable value semantics, which allows in-place mutation, including across function boundaries, but forbids pointers and references. Instead, objects are independent entities that can never be accessed mutably via different names. Val also checks generic definitions at declaration to ensure that algorithms never rely on unspecified properties of their inputs.

Nonetheless, if we look carefully, we realize that Val and C++ are actually very close. Both are zero-cost abstraction languages that fully acknowledge the physical constraints of computer architecture, yet manage to build efficient generic abstractions. Perhaps they could become friends so that, one day, developers can write fast-by-definition and safe-by-default Val code that seamlessly calls into C++, and vice-versa. Perhaps their relationship could even grow stronger, who knows?

This talk will refer to some of contents presented by Dave Abrahams in his talk titled: "Values: regularity, independence, projection, and the future of programming".

Dimitri Racordon

Post-doc researcherNortheastern University

Dimitri is a researcher at Northeastern University, in the US.

He might a bit of an outsider at CppCon. He's never been a real software developer. He doesn't have clients or a product owner to satisfy so he can get away only writing proof of concepts. He has a Ph.D. in computer science, but only because he bribed his jury members with Swiss chocolate. He used to work on model checking for concurrent programs before getting into programming language design. Now he writes formal proofs for a living and has yet to prove someone else reads them. He also likes coding very, very much.

Because he knows he's not so good at writing correct programs, though, Dimitri thought he'd better write cleverer compilers. The bar wasn't so high but the quest led him to interesting research questions. Eventually, he developed a true passion for type-based approaches to memory safety. Further, because he constantly falls into the traps of premature optimization, Dimitri believes that languages should offer transparent abstractions with predictable costs that free the user from thinking about performance all the time.

Dimitri likes generic programming, because it looks like math. He also likes low-level programming languages. Since he's not good enough to write C++ and thinks he's too cool for Rust, he decided to focus his research on yet another programming language. He says he's "discovering" a core calculus to build a "safe by default" and "fast by definition" language that interoperate with C++.