Agda source code accompanying the paper (DTP 2013):
Code from the paper
- A typical, IR dependently typed universe without a hierarchy.
- Section 2 of the paper.
- A dependently typed universe with some base types and a universe hierarchy.
- The generic definition of
- Sections 4 and 5 of the paper.
The underlying type system
- A denotational semantics for terms, or terms with an implicit context.
- An operational semantics for terms, or terms with an explicit context.
- This extends McBride's type-safe syntax and evaluation to include a universe hierarchy.
- Compared to McBride's types and terms, here the types and terms (and descriptions) are in a single grammar/datatype.
Extra examples of generic functions over indexed types
- A fixed dependently typed universe with some indexed types in it.
- Contains examples of applying a generic double over indexed types. Applying generic functions to dependent types changes the result type, prefixing them by Π's that act as "preconditions" that are used to preserve type correctness.
- Generically double the dependent function `fun and get results out by satisfying its generated preconditions.
- Generically double the dependent pair `pair and get results out by satisfying its generated preconditions.
Extras.FixedHierarchyEverywhereWARNING: CONTAINS OMGBBQ AWESOME!