Skip to content

Commit

Permalink
gh-38288: Deprecate is_Ring
Browse files Browse the repository at this point in the history
    
<!-- ^ Please provide a concise and informative title. -->
<!-- ^ Don't put issue numbers in the title, do this in the PR
description below. -->
<!-- ^ For example, instead of "Fixes #12345" use "Introduce new method
to calculate 1 + 2". -->
<!-- v Describe your changes below in detail. -->
<!-- v Why is this change required? What problem does it solve? -->
<!-- v If this PR resolves an open issue, please link to it here. For
example, "Fixes #12345". -->

Unused in the Sage library.

- Part of #32414

### 📝 Checklist

<!-- Put an `x` in all the boxes that apply. -->

- [x] The title is concise and informative.
- [x] The description explains in detail what this PR is about.
- [x] I have linked a relevant issue or discussion.
- [ ] I have created tests covering the changes.
- [ ] I have updated the documentation and checked the documentation
preview.

### ⌛ Dependencies

<!-- List all open PRs that this PR logically depends on. For example,
-->
<!-- - #12345: short description why this is a dependency -->
<!-- - #34567: ... -->
    
URL: #38288
Reported by: Matthias Köppe
Reviewer(s): Kwankyu Lee
  • Loading branch information
Release Manager committed Jul 20, 2024
2 parents 69b39f7 + 505eaed commit 4efc355
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/sage/rings/ring.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -1646,9 +1646,16 @@ def is_Ring(x):
sage: from sage.rings.ring import is_Ring
sage: is_Ring(ZZ)
doctest:warning...
DeprecationWarning: The function is_Ring is deprecated; use '... in Rings()' instead
See https://github.com/sagemath/sage/issues/38288 for details.
True
sage: MS = MatrixSpace(QQ, 2) # needs sage.modules
sage: is_Ring(MS) # needs sage.modules
True
"""
from sage.misc.superseded import deprecation_cython
deprecation_cython(38288,
"The function is_Ring is deprecated; "
"use '... in Rings()' instead")
return x in _Rings

0 comments on commit 4efc355

Please sign in to comment.