Zulip Chat Archive

Stream: Is there code for X?

Topic: Lifting is_empty instance


Yaël Dillies (Dec 21 2021 at 23:45):

Do we not have this anywhere?

lemma is_empty_lift {α β : Type*} [is_empty β] (f : α  β) : is_empty α :=
-- or
lemma is_empty.lift {α β : Type*} (is_empty β) (f : α  β) : is_empty α :=

Adam Topaz (Dec 21 2021 at 23:46):

docs#function.is_empty

Yaël Dillies (Dec 21 2021 at 23:49):

Ah thanks! Was looking in the wrong namespace.

Kevin Buzzard (Dec 21 2021 at 23:51):

I'm assuming dot notation doesn't work f.is_empty?

Adam Topaz (Dec 21 2021 at 23:52):

Yeah, is_empty.comap is perhaps a better name?

Yaël Dillies (Dec 21 2021 at 23:55):

That's what I was dreaming of.


Last updated: Dec 20 2023 at 11:08 UTC