Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get rid of references to PyInt in Py3 sources #67072

Closed
serhiy-storchaka opened this issue Nov 16, 2014 · 3 comments
Closed

Get rid of references to PyInt in Py3 sources #67072

serhiy-storchaka opened this issue Nov 16, 2014 · 3 comments
Labels
docs Documentation in the Doc dir easy

Comments

@serhiy-storchaka
Copy link
Member

BPO 22883
Nosy @mdickinson, @serhiy-storchaka
Files
  • issue22883.patch
  • issue228813_msg232419.patch: added changes according to msg232419
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2015-02-17.08:32:30.868>
    created_at = <Date 2014-11-16.14:12:26.471>
    labels = ['easy', 'docs']
    title = 'Get rid of references to PyInt in Py3 sources'
    updated_at = <Date 2015-02-17.08:32:30.867>
    user = 'https://github.com/serhiy-storchaka'

    bugs.python.org fields:

    activity = <Date 2015-02-17.08:32:30.867>
    actor = 'serhiy.storchaka'
    assignee = 'docs@python'
    closed = True
    closed_date = <Date 2015-02-17.08:32:30.868>
    closer = 'serhiy.storchaka'
    components = ['Documentation']
    creation = <Date 2014-11-16.14:12:26.471>
    creator = 'serhiy.storchaka'
    dependencies = []
    files = ['37408', '37417']
    hgrepos = []
    issue_num = 22883
    keywords = ['patch', 'easy']
    message_count = 3.0
    messages = ['231246', '232419', '236128']
    nosy_count = 4.0
    nosy_names = ['mark.dickinson', 'docs@python', 'python-dev', 'serhiy.storchaka']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue22883'
    versions = ['Python 3.4', 'Python 3.5']

    @serhiy-storchaka
    Copy link
    Member Author

    There are several references to PyInt in outdated comments in .c and .h files:

    $ find * -name '*.[ch]' -exec egrep -n --color -- 'PyInt\b' '{}' +
    Include/longobject.h:34:/* It may be useful in the future. I've added it in the PyInt -> PyLong
    Modules/fcntlmodule.c:157:       into either a large positive number (PyLong or PyInt on 64-bit
    Modules/fcntlmodule.c:158:       platforms) or a negative number on others (32-bit PyInt)
    Modules/_json.c:813:        PyInt, PyLong, or PyFloat.
    Modules/itertoolsmodule.c:3869:    assert(cnt != PY_SSIZE_T_MAX && long_cnt == NULL && long_step==PyInt(1));
    Python/ceval.c:4606:/* Extract a slice index from a PyInt or PyLong or an object with the

    @serhiy-storchaka serhiy-storchaka added extension-modules C modules in the Modules dir interpreter-core (Objects, Python, Grammar, and Parser dirs) labels Nov 16, 2014
    @serhiy-storchaka
    Copy link
    Member Author

    I doubt that just removing PyInt is correct. At least in longobject.h current comment looks correct. And in fcntlmodule.c and itertoolsmodule.c proposed changes look questionable.

    There are also mentions of PyInt_* in *.rst and *.py files.

    @serhiy-storchaka serhiy-storchaka added docs Documentation in the Doc dir and removed extension-modules C modules in the Modules dir interpreter-core (Objects, Python, Grammar, and Parser dirs) labels Feb 10, 2015
    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Feb 17, 2015

    New changeset 2f0c1937d716 by Serhiy Storchaka in branch 'default':
    Issue bpo-22883: Got rid of outdated references to PyInt and PyString in comments.
    https://hg.python.org/cpython/rev/2f0c1937d716

    New changeset c8d08de14030 by Serhiy Storchaka in branch '3.4':
    Issue bpo-22883: Update PyInt to PyLong in C API example.
    https://hg.python.org/cpython/rev/c8d08de14030

    New changeset c0b2dacef35c by Serhiy Storchaka in branch 'default':
    Issue bpo-22883: Update PyInt to PyLong in C API example.
    https://hg.python.org/cpython/rev/c0b2dacef35c

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    docs Documentation in the Doc dir easy
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant