FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

bpo-34392: Add sys. _is_interned() by serhiy-storchaka · Pull Request #8755 · python/cpython · GitHub

Repository navigation

bpo-34392: Add sys. _is_interned() - #8755

Merged
serhiy-storchaka merged 11 commits into
python:mainfrom
serhiy-storchaka:sys-isinterned
Dec 4, 2023
Merged

serhiy-storchaka merged 11 commits into
python:mainfrom
serhiy-storchaka:sys-isinterned

Conversation

serhiy-storchaka commented Aug 13, 2018 •
edited
Loading

Copy link
Copy Markdown
Member

Comment thread Python/sysmodule.c
sys_isinterned_impl(PyObject *module, PyObject *string)
/*[clinic end generated code: output=0364c3f36499f868 input=2fe09bef8edf732e]*/
{
return PyUnicode_CHECK_INTERNED(string);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Question: Currently sys.internmakes a PyUnicode_CheckExact(s) over the string so interning a subclass of a string gives a TypeError back. This returns False. Does it make sense to do a exact check to mirror the interface of sys.intern?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

I don't know.

Copy link
Copy Markdown
Contributor

@methane, should this be merged after fixing the merge conflicts? Thanks!

methane changed the title bpo-34392: Add sys.isinterned(). bpo-34392: Add sys. _is_interned() May 26, 2020

methane commented May 26, 2020

Copy link
Copy Markdown
Member

@methane, should this be merged after fixing the merge conflicts? Thanks!

Up to @serhiy-storchaka. He wanted this API to write some tests.

…92.9kIlMF.rst

Co-authored-by: Inada Naoki <songofacandy@gmail.com>

iritkatriel left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

This has merge conflicts now.

Copy link
Copy Markdown

When you're done making the requested changes, leave the comment: I have made the requested changes; please review again.

Copy link
Copy Markdown
Member Author

I have made the requested changes; please review again.

serhiy-storchaka dismissed iritkatriel’s stale review December 4, 2023 09:06

Merge conflicts are resolved.

serhiy-storchaka merged commit dee7bee into python:main Dec 4, 2023
serhiy-storchaka deleted the sys-isinterned branch December 4, 2023 09:09
aisk pushed a commit to aisk/cpython that referenced this pull request Feb 11, 2024
Glyphack pushed a commit to Glyphack/cpython that referenced this pull request Sep 2, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type-feature A feature request or enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants


Back | FazBrowse Home | New Git URL