danidiaz/really-small-backpack-example

A really small example of the Backpack module system for Haskell

Haskell

59

29 commits

updated Dec 9, 2025

See the code

README

really-small-backpack-example

This is a small tutorial on the very basics of the Backpack module system. (Well... at least it started that way. It has grown a bit over time.)

It requires cabal-install >= 3.2.0.0 and GHC >= 9.0.1. You can install both using ghcup.

It is a multi-package project. You can build all the packages from this folder using:

cabal build all

Any corrections welcome!

lessons

Further resources for learning Backpack

User guides

The theory behind Backpack

  • Edward Z. Yang's thesis is quite readable and gives a good account of the motivations for Backpack.

  • Edward Z. Yang's blog.

  • Scott Kilpatrick's thesis. Not as directly applicable to the current implementation of Backpack as Edward Z. Yang's thesis, but useful insights can be gleaned here.

The implementation

Stuff about module systems in general

backpack
haskell
tutorial

Contributors

danidiaz

27 commits

sourabhxyz

1 commits

ulysses4ever

1 commits

danidiaz/really-small-backpack-example

A really small example of the Backpack module system for Haskell

Haskell

59

29 commits

updated Dec 9, 2025

See the code

README

really-small-backpack-example

This is a small tutorial on the very basics of the Backpack module system. (Well... at least it started that way. It has grown a bit over time.)

It requires cabal-install >= 3.2.0.0 and GHC >= 9.0.1. You can install both using ghcup.

It is a multi-package project. You can build all the packages from this folder using:

cabal build all

Any corrections welcome!

lessons

Further resources for learning Backpack

User guides

The theory behind Backpack

  • Edward Z. Yang's thesis is quite readable and gives a good account of the motivations for Backpack.

  • Edward Z. Yang's blog.

  • Scott Kilpatrick's thesis. Not as directly applicable to the current implementation of Backpack as Edward Z. Yang's thesis, but useful insights can be gleaned here.

The implementation

Stuff about module systems in general

backpack
haskell
tutorial

Contributors

danidiaz

27 commits

sourabhxyz

1 commits

ulysses4ever

1 commits

Languages

Haskell

100.0%