Skip to content

3.6 default parameter handling  #138

@rocky

Description

@rocky
def foo1(bar, baz=1):
    return 1
def foo2(bar, baz, qux=1):
    return 2
def foo3(bar, baz=1, qux=2):
    return 3
def foo4(bar, baz, qux=1, quux=2):
    return 4

deocompiles on 3.6 to:

def foo1(bar, baz = (1,)):
    return 1


def foo2(bar, baz, qux = (1,)):
    return 2


def foo3(bar, baz, qux = (1, 2)):
    return 3


def foo4(bar, baz, qux, quux = (1, 2)):
    return 4

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions