~/talk

Representing Data Structures with Invariants in Haskell: the cases of BST and AVL

Talkat TyDe 2025 · on Sunday, 2025-10-12· [functional-programming]
links:none on file
links:none on file
links:none on file
slides:none on file

Three concrete encodings for BSTs and AVLs in Haskell are implemented and compared: a proof-paired EBST paired with proof that stores a separate inductive proof term, an externalized variant that attaches preservation proofs to each operation, and an integrated IBST correctness-by-construction type that forces invariants at construction time. Keys are promoted to type-level naturals via proxies, insertion is implemented as coupled type- and value-level functions with instance-resolution synthesis of proofs, compilation time rises exponentially with tree size, and a systematic translation to undecorated code yields standard, efficient BST/AVL implementations after removing proof baggage.

AI-written summary · about

  1. 0:00Invariants in Haskell data structures
  2. 1:49Approaches to enforce invariants
  3. 3:19BST structure in Haskell
  4. 8:19Externalist approach with proofs
  5. 12:50Type-safe BST operations
  6. 16:50Explicit proof approach
  7. 20:44Correctness by construction
  8. 23:13Drawbacks of invariant checking
  9. 24:23Efficient implementations
  10. 27:30AVL trees with invariants
  11. 28:13Comparing approaches
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.