<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/63201>63201</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [clang/c++ bug] Clang fails to compare simple struct values
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          yurivict
      </td>
    </tr>
</table>

<pre>
    Testcase:
```
struct Pt {
 float x;
        float y;
};

bool e(const Pt &pt) {
 return pt == Pt{1.f, 1.f}; // fails: error: invalid operands to binary expression ('const Pt' and 'Pt')
        //return pt == (const Pt)Pt{1.f, 1.f}; // fails: error: invalid operands to binary expression ('const Pt' and 'const Pt')
}
```

Both above lines fail.

A simple structure value should be comparable using the default operator== that should be auto-generated for Pt.


clang-15.0.7
clang-16.0.4
FreeBSD 13.2
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy8U8uuqzoM_RozsYqCeZUBg3Yjxlu69wcCGMhVSlAevbt_fwTsR6tzxqeqnGSR2Gv5IZ1T08JcQ36FvIlk8LOx9SNYdVe9jzozPOp_2fleOob0AqIBcYFCfP73o_M29B7fPUJ5PSActZEePyD9Aj5_B_74xqFsfva77YzRyEDn3izu8ErF6oGqJ_eWfbALrh4hbSBt8N1DeU3iEegNt2V3i0AtUIujVNpBekG21thto5a71GpAs7KVy-DQG-zUIu0D-WO17JwyCwKdgcovHkAlymVAoHI_AFWv2o5ov1F7kgJU_V2iT9A33S3kn8p42KvxM8rO3Bm1WtjtnOLnGxd06rZqxqPuwTLepQ6MbjZBD9gx9ua2Sis7zRicWib0M-PAowzaH1L8Jm9Pj5-lf3oqgzeniZftDg84Govv_iX-YXstl-mU5LGIyxekiEWcHUhrma__NJikMUVDnQ5VWsmI66Q4F5Sfz1UezXVSliRkWeVJz_I8yG5Iq24su5zGNGPOIlWToFQU4kxJkuVZLIaxqLIqy2SZChpKyATftixpfb_Fxk6Rci5wXaQkkkjLjrXbB4xo4f9x_whE27zZentz6sLkIBNaOe9-vHjl9T6ZuzKgtge6Al2xCxPkDb5t8NEzW1scSefX6hylcVGwup69X7fuOpptUn4OXdybG1C7xfxcTqs1_3HvgdqdqQNqdyW_AgAA__8EtT9u">