def METHOD_NAME():
    def f(x, g):
        match x:
            case x if g == 1:
                return 42
            case _:
                return 0
    assert f(1, 1) == 42
    assert f(1, 2) == 0
    def f(x):
        match x:
            case x as g if g == 1:
                return 42
            case _:
                return 0
    assert f(1) == 42
    assert f(2) == 0