Unless SpaceBeforeParensOptions is set to SBPO_Never, a space will be put between using and ( in C# code.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/unittests/Format/FormatTestCSharp.cpp | ||
---|---|---|
259 | I'm following the example set by by test cases above. I can remove (all) if you prefer and agree it does not test anything new. |
clang/unittests/Format/FormatTestCSharp.cpp | ||
---|---|---|
259 | I didn't notice the old example. Yes, please remove all of them. |
Actually i would prefer we didn't remove those tests, because we added them because previously someone called out that it had that effect when at the top level
because clang-format can work on a snippet of code it may be that you don't see the outer scope, I see those tests doing no harm and they assert the behaviour that was previously seen to be different for both in scope and toplevel
Extended tests and added some comments explaining why seeming duplicated tests are useful.
I looked up the C# reference and all the examples are top-level, so having top-level test cases here would be useful, as people would expect copy-pasting an example snippet to just work.
Sorry about asking you to go back-and-forth.
Please also add a test for SBPO_NonEmptyParentheses.