English

Featherweight Go

Programming Languages 2020-10-20 v4 Logic in Computer Science

Abstract

We describe a design for generics in Go inspired by previous work on Featherweight Java by Igarashi, Pierce, and Wadler. Whereas subtyping in Java is nominal, in Go it is structural, and whereas generics in Java are defined via erasure, in Go we use monomorphisation. Although monomorphisation is widely used, we are one of the first to formalise it. Our design also supports a solution to The Expression Problem.

Cite

@article{arxiv.2005.11710,
  title  = {Featherweight Go},
  author = {Robert Griesemer and Raymond Hu and Wen Kokke and Julien Lange and Ian Lance Taylor and Bernardo Toninho and Philip Wadler and Nobuko Yoshida},
  journal= {arXiv preprint arXiv:2005.11710},
  year   = {2020}
}

Comments

Full version

R2 v1 2026-06-23T15:46:03.644Z