Skip to content

Operator overload #2761

Closed
Closed
@HerrCai0907

Description

@HerrCai0907

new A() == new B() and new B() == new A() will call different operator overload functions if both A and B have overload function declarations.

It needs more clear rules to handle it.
In my opinion there are two solutions:

  1. Diagnose when confused overload resolution.
  2. Define priorities and do overload resolution according to priorities.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions