batteries icon indicating copy to clipboard operation
batteries copied to clipboard

feat: backport `Function.Injective` etc from Mathlib

Open urkud opened this issue 1 year ago • 8 comments

Also move Std.Logic to Std.Logic.Basic.

urkud avatar Jan 11 '24 08:01 urkud

I changed some names and deduplicated lemmas while backporting, so review carefully, please.

urkud avatar Jan 11 '24 08:01 urkud

Std.Logic should be re-added as a import-only file for backward compatibility

digama0 avatar Jan 11 '24 08:01 digama0

awaiting-review

urkud avatar Jan 11 '24 14:01 urkud

I changed some names and deduplicated lemmas while backporting, so review carefully, please.

I'm not suggesting going back in this instance, but I think it is usually overall easier to do the refactor in Mathlib, then have a copy-and-paste migration to Std, then have a just-delete-stuff adaptation PR to Mathlib, rather than risking having a nightmarish adaptation PR to Mathlib due to unexpected consequences of changes during the migration.

kim-em avatar Jan 12 '24 06:01 kim-em

I changed some names and deduplicated lemmas while backporting, so review carefully, please.

I'm not suggesting going back in this instance, but I think it is usually overall easier to do the refactor in Mathlib, then have a copy-and-paste migration to Std, then have a just-delete-stuff adaptation PR to Mathlib, rather than risking having a nightmarish adaptation PR to Mathlib due to unexpected consequences of changes during the migration.

Thank you for the information. I volunteer to adapt Mathlib.

urkud avatar Jan 12 '24 15:01 urkud

I've started doing the same changes in Mathlib, see leanprover-community/mathlib4#9738 for the first batch. Let's wait with merging this PR till I sync Mathlib with it.

awaiting-author

urkud avatar Jan 14 '24 22:01 urkud

UPD: @sgouezel is working on changing Surjective f from ∀ y, ∃ x, f x = y to ∀ y, ∃ x, y = f x. Waiting for updates.

urkud avatar Jan 24 '24 15:01 urkud