Skip to content

[Merged by Bors] - chore: Rename nat_cast/int_cast/rat_cast to natCast/intCast/ratCast#11486

Closed
YaelDillies wants to merge 34 commits intomasterfrom
rename_cast
Closed

[Merged by Bors] - chore: Rename nat_cast/int_cast/rat_cast to natCast/intCast/ratCast#11486
YaelDillies wants to merge 34 commits intomasterfrom
rename_cast

Conversation

@YaelDillies
Copy link
Copy Markdown
Contributor

Now that I am defining NNRat.cast, I want a definitive answer to this naming issue. Plenty of lemmas in mathlib already use natCast/intCast/ratCast over nat_cast/int_cast/rat_cast, and this matches with the general expectation that underscore-separated name parts correspond to a single declaration.


Open in Gitpod

Now that I am defining `NNRat.cast`, I want a definitive answer to this naming issue. Plenty of lemmas in mathlib already use `natCast`/`intCast`/`ratCast` over `nat_cast`/`int_cast`/`rat_cast`, and this matches with the general expectation that underscore-separated name parts correspond to a single declaration.
@YaelDillies YaelDillies added awaiting-review awaiting-CI This PR does not pass CI yet. This label is automatically removed once it does. t-algebra Algebra (groups, rings, fields, etc) labels Mar 18, 2024
@github-actions github-actions bot removed the awaiting-CI This PR does not pass CI yet. This label is automatically removed once it does. label Mar 18, 2024
@eric-wieser
Copy link
Copy Markdown
Member

@YaelDillies
Copy link
Copy Markdown
Contributor Author

Seems like there's a majority in favour

@YaelDillies YaelDillies changed the title chore: Rename to natCast/intCast/ratCast chore: Rename nat_cast/int_cast/rat_cast to natCast/intCast/ratCast Mar 19, 2024
@ghost ghost added the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Mar 20, 2024
@ghost ghost added merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) and removed merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) labels Mar 20, 2024
@ghost ghost added merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) and removed merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) labels Mar 20, 2024
@ghost ghost added merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) and removed merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) labels Mar 21, 2024
@ghost ghost added merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) and removed merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) labels Mar 21, 2024
@ghost ghost removed the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Mar 23, 2024
@ghost ghost added the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Apr 15, 2024
xgenereux pushed a commit that referenced this pull request Apr 15, 2024
…atCast` (#11499)

This is less exhaustive than its sibling #11486 because edge cases are harder to classify. No fundamental difficulty, just me being a bit fast and lazy.

Reduce the diff of #11203
@ghost ghost removed the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Apr 15, 2024
atarnoam pushed a commit that referenced this pull request Apr 16, 2024
…atCast` (#11499)

This is less exhaustive than its sibling #11486 because edge cases are harder to classify. No fundamental difficulty, just me being a bit fast and lazy.

Reduce the diff of #11203
@ghost ghost added the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Apr 16, 2024
@kim-em
Copy link
Copy Markdown
Contributor

kim-em commented Apr 17, 2024

bors d+

@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Apr 17, 2024

✌️ YaelDillies can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@github-actions github-actions bot added delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). and removed awaiting-review labels Apr 17, 2024
@ghost ghost removed the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Apr 17, 2024
@YaelDillies
Copy link
Copy Markdown
Contributor Author

bors merge

mathlib-bors bot pushed a commit that referenced this pull request Apr 17, 2024
…/`ratCast` (#11486)

Now that I am defining `NNRat.cast`, I want a definitive answer to this naming issue. Plenty of lemmas in mathlib already use `natCast`/`intCast`/`ratCast` over `nat_cast`/`int_cast`/`rat_cast`, and this matches with the general expectation that underscore-separated name parts correspond to a single declaration.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Apr 17, 2024

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title chore: Rename nat_cast/int_cast/rat_cast to natCast/intCast/ratCast [Merged by Bors] - chore: Rename nat_cast/int_cast/rat_cast to natCast/intCast/ratCast Apr 17, 2024
@mathlib-bors mathlib-bors bot closed this Apr 17, 2024
@mathlib-bors mathlib-bors bot deleted the rename_cast branch April 17, 2024 12:17
uniwuni pushed a commit that referenced this pull request Apr 19, 2024
…atCast` (#11499)

This is less exhaustive than its sibling #11486 because edge cases are harder to classify. No fundamental difficulty, just me being a bit fast and lazy.

Reduce the diff of #11203
uniwuni pushed a commit that referenced this pull request Apr 19, 2024
…/`ratCast` (#11486)

Now that I am defining `NNRat.cast`, I want a definitive answer to this naming issue. Plenty of lemmas in mathlib already use `natCast`/`intCast`/`ratCast` over `nat_cast`/`int_cast`/`rat_cast`, and this matches with the general expectation that underscore-separated name parts correspond to a single declaration.
callesonne pushed a commit that referenced this pull request Apr 22, 2024
…atCast` (#11499)

This is less exhaustive than its sibling #11486 because edge cases are harder to classify. No fundamental difficulty, just me being a bit fast and lazy.

Reduce the diff of #11203
callesonne pushed a commit that referenced this pull request Apr 22, 2024
…/`ratCast` (#11486)

Now that I am defining `NNRat.cast`, I want a definitive answer to this naming issue. Plenty of lemmas in mathlib already use `natCast`/`intCast`/`ratCast` over `nat_cast`/`int_cast`/`rat_cast`, and this matches with the general expectation that underscore-separated name parts correspond to a single declaration.
fpvandoorn pushed a commit to leanprover-community/leanprover-community.github.io that referenced this pull request Apr 24, 2024
Explain the naming convention pushed for by leanprover-community/mathlib4#11486.
Jun2M pushed a commit that referenced this pull request Apr 24, 2024
…/`ratCast` (#11486)

Now that I am defining `NNRat.cast`, I want a definitive answer to this naming issue. Plenty of lemmas in mathlib already use `natCast`/`intCast`/`ratCast` over `nat_cast`/`int_cast`/`rat_cast`, and this matches with the general expectation that underscore-separated name parts correspond to a single declaration.
mathlib-bors bot pushed a commit that referenced this pull request May 30, 2024
…3368)

Deprecations have been forgotten in #11486. We add them in this PR.

Methodology: start from the last commit of #11486, use the script by @adomani in #10185 (comment) to generate deprecation aliases (I am also adding an updated version of the script in a comment below) and commit. Then cherry pick this last commit on master and fix whatever has changed in between. This is not perfect as declarations which have been moved since #11486 won't get their deprecated alias, but this should be good enough.
callesonne pushed a commit that referenced this pull request Jun 4, 2024
…3368)

Deprecations have been forgotten in #11486. We add them in this PR.

Methodology: start from the last commit of #11486, use the script by @adomani in #10185 (comment) to generate deprecation aliases (I am also adding an updated version of the script in a comment below) and commit. Then cherry pick this last commit on master and fix whatever has changed in between. This is not perfect as declarations which have been moved since #11486 won't get their deprecated alias, but this should be good enough.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). t-algebra Algebra (groups, rings, fields, etc)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants