Skip to content

Dead initialization in parse_abbr function #87526

Description

@alexhenrie
mannequin
BPO 43360
Nosy @alexhenrie
PRs
  • gh-87526: Remove dead initialization from parse_abbr function #24700
  • 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 = None
    created_at = <Date 2021-03-02.02:25:12.944>
    labels = ['type-feature', 'library', '3.10']
    title = 'Dead initialization in parse_abbr function'
    updated_at = <Date 2021-03-02.02:26:22.031>
    user = 'https://github.com/alexhenrie'

    bugs.python.org fields:

    activity = <Date 2021-03-02.02:26:22.031>
    actor = 'alex.henrie'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Library (Lib)']
    creation = <Date 2021-03-02.02:25:12.944>
    creator = 'alex.henrie'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 43360
    keywords = ['patch']
    message_count = 1.0
    messages = ['387895']
    nosy_count = 1.0
    nosy_names = ['alex.henrie']
    pr_nums = ['24700']
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue43360'
    versions = ['Python 3.10']

    Activity

    1. alexhenrie commented on Mar 2, 2021

      alexhenriemannequin
      MannequinAuthor

      The parse_abbr function in _zoneinfo.c currently initializes the variable buff regardless of whether it is going to be used, and then initializes it again in the one path that does use it. The first initialization could be removed to simplify the code and clarify its intent.

      Defect identified by scan-build <https://clang-analyzer.llvm.org/scan-build.html\>

    2. added
      stdlibStandard Library Python modules in the Lib/ directory
      type-featureA feature request or enhancement
      on Mar 2, 2021
    3. transferred this issue fromon Apr 10, 2022
    4. added a commit that references this issue on May 12, 2023
    5. added a commit that references this issue on May 12, 2023
    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

      stdlibStandard Library Python modules in the Lib/ directorytype-featureA feature request or enhancement

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions