Skip to content

redundant self type is unusable #1399

@jvasileff

Description

@jvasileff

I'm not sure what to make of this, but a value that satisfies a self type two different ways cannot be used:

void boxIntersection<I>(I i)
        given I satisfies Summable<I> {

    assert (is Integer i);

    print(i + i);
    // Right operand must be of compatible summable type:
    // type cannot be determined

    print((i of Integer) + i); // ok
    print((i of I) + i); // ok
}

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions