[PATCH] D75465: [clang-format] Do not merge target-name and : for C# attributes
Krasimir Georgiev via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 2 16:38:30 PST 2020
krasimir added inline comments.
================
Comment at: clang/unittests/Format/FormatTestCSharp.cpp:281
Style.ColumnLimit = 10;
- verifyFormat(R"([assembly:InternalsVisibleTo(
+ verifyFormat(R"([assembly: InternalsVisibleTo(
"SomeAssembly, PublicKey=SomePublicKeyThatExceedsTheColumnLimit")])",
----------------
krasimir wrote:
> isn't the space after the `:` a regression?
> Looking at
> https://docs.microsoft.com/en-us/dotnet/standard/assembly/set-attributes
> it looks like such attributes are spelled `[assembly:Blah]`
>
> How is an example where such an attribute is not the last thing in the file?
>
> I'm not entirely clear on which edit caused this.
The space maybe is coming from
[[ https://github.com/llvm/llvm-project/blob/ff9f4b5489cda4d9b31595b54ec0296dc012588d/clang/lib/Format/TokenAnnotator.h#L177 | TokenAnnotator.spaceRequiredBetween ]], which may need to be adjusted for C#.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D75465/new/
https://reviews.llvm.org/D75465
More information about the cfe-commits
mailing list