FreshLists skeleton

This commit is contained in:
Nathan McCarty 2025-03-15 18:22:52 -04:00
parent d79c4b6f46
commit 8fc5a0fbda
4 changed files with 32 additions and 0 deletions

View file

@ -19,6 +19,7 @@ authors = "Nathan McCarty"
modules = Idris
, Posts.HelloWorld
, LessMacrosMoreTypes.Printf
, DependentNuggets.FreshLists
-- main file (i.e. file to load at REPL)
-- main =

View file

@ -0,0 +1,8 @@
# FreshLists: Containers That Only Accept "Fresh" Elements
```idris hide
module DependentNuggets.FreshLists
```
When programming, we quite frequently encounter the for a data structure that can contain at most one of each given element. Typically, we would use a `Set`, which satisfies this constraint, but does so as a runtime invariant that must be taken on trust, and results in ergonomic concerns when used as a component of API design.