lean4-htt/tests/lean/setLit.lean
Leonardo de Moura 9e27e92eea
chore: set literal notation (#3348)
Co-authored-by: Sebastian Ullrich <sebasti@nullri.ch>
2024-02-19 23:22:36 +00:00

24 lines
405 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

structure Foo where
val := 10
instance : Singleton α (List α) where
singleton a := [a]
instance : Insert α (List α) where
insert a as := a :: as
def f1 : Foo := {}
def f2 : List Nat := {}
def f3 : List Nat := {1, 2}
def f4 (a : Nat) : List Nat := {a}
def f5 (val : Nat) : Foo := {val}
def f6 (val : Nat) : List Nat := {val}
def f7 : String := {}
def f8 (val : Nat) : String := { val }