curdeius added inline comments.
================
Comment at: clang/unittests/Format/FormatTest.cpp:9662
+TEST_F(FormatTest, AmpAmpOperator) {
+ verifyFormat("int operator()(T (&&)[N]) { return 1; }");
----------------
Nit: these are not &/&& operators but references so the test name seems
incorrect.
================
Comment at: clang/unittests/Format/FormatTest.cpp:21879
verifyFormat("Foo::operator&&();", Style);
- verifyFormat("operator&&(int(&&)(), class Foo);", Style);
+ verifyFormat("operator&&(int (&&)(), class Foo);", Style);
verifyFormat("operator const nsTArrayRight<E> &()", Style);
----------------
MyDeveloperDay wrote:
> this test should be consistent with
>
> ```
> verifyFormat("operator&(int (&)(), class Foo);", Style);
> ```
Should we test
```
verifyFormat("operator&&(int (&)(), class Foo);", Style);
```
here, and
```
verifyFormat("operator&(int (&&)(), class Foo);", Style);
```
above as well?
================
Comment at: clang/unittests/Format/FormatTest.cpp:21940
verifyFormat("Foo::operator&&();", Style);
- verifyFormat("operator&&(int(&&)(), class Foo);", Style);
+ verifyFormat("operator&&(int (&&)(), class Foo);", Style);
verifyFormat("operator const nsTArrayLeft<E>&()", Style);
----------------
Ditto for combinations of &+(&&) and &&+(&).
================
Comment at: clang/unittests/Format/FormatTest.cpp:21981
verifyFormat("Foo::operator&&();", Style);
- verifyFormat("operator&&(int(&&)(), class Foo);", Style);
+ verifyFormat("operator&&(int (&&)(), class Foo);", Style);
}
----------------
Ditto.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D114519/new/
https://reviews.llvm.org/D114519
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits