Skip to content

Deprecate returning a subclass of complex from __complex__ #74080

Closed

Description

@serhiy-storchaka
BPO 29894
Nosy @mdickinson, @serhiy-storchaka
PRs
  • bpo-29894: Deprecate returning an instance of complex subclass from __complex__ #798
  • 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 2017-03-27.18:06:06.242>
    created_at = <Date 2017-03-24.08:27:24.474>
    labels = ['interpreter-core', 'type-feature', '3.7']
    title = 'Deprecate returning a subclass of complex from __complex__'
    updated_at = <Date 2017-03-27.18:06:06.241>
    user = 'https://github.com/serhiy-storchaka'

    bugs.python.org fields:

    activity = <Date 2017-03-27.18:06:06.241>
    actor = 'serhiy.storchaka'
    assignee = 'none'
    closed = True
    closed_date = <Date 2017-03-27.18:06:06.242>
    closer = 'serhiy.storchaka'
    components = ['Interpreter Core']
    creation = <Date 2017-03-24.08:27:24.474>
    creator = 'serhiy.storchaka'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 29894
    keywords = []
    message_count = 2.0
    messages = ['290080', '290108']
    nosy_count = 2.0
    nosy_names = ['mark.dickinson', 'serhiy.storchaka']
    pr_nums = ['798']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue29894'
    versions = ['Python 3.7']

    Activity

    1. serhiy-storchaka commented on Mar 24, 2017

      @serhiy-storchaka
      MemberAuthor

      This is similar to bpo-26983, but complex() always returned exact complex. A deprecation warning is added just for uniformity with __float__ and __int__.

    2. added
      type-bugAn unexpected behavior, bug, or error
      interpreter-core(Objects, Python, Grammar, and Parser dirs)
      type-featureA feature request or enhancement
      and removed
      type-bugAn unexpected behavior, bug, or error
      on Mar 24, 2017
    3. serhiy-storchaka commented on Mar 24, 2017

      @serhiy-storchaka
      MemberAuthor

      New changeset 671079e by Serhiy Storchaka in branch 'master':
      bpo-29894: Deprecate returning an instance of complex subclass from __complex__. (#798)
      671079e

    4. transferred this issue fromon Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      3.7 (EOL)end of lifeinterpreter-core(Objects, Python, Grammar, and Parser dirs)type-featureA feature request or enhancement

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions