[cfe-dev] LLVM coding style regarding consecutive angle brackets (>>) in templates

David Blaikie via cfe-dev cfe-dev at lists.llvm.org
Mon Aug 20 10:27:02 PDT 2018


On Mon, Aug 20, 2018 at 7:24 AM Oren Ish-Shalom via cfe-dev <
cfe-dev at lists.llvm.org> wrote:

> Hi all,
>
> This SO post
> <https://stackoverflow.com/questions/51929037/llvm-coding-style-regarding-consecutive-angle-brackets-in-templates?noredirect=1#comment90813882_51929037> is
> regarding the status of consecutive angle brackets in templates.
> I'm writing here too, hoping to get a certified answer.
>
> Since it is legal to write:
>
>     vector<vector<float>> MyMatrix;
>
> and not just:
>
>     // vector<vector<float> > MyMatrix;
>
> I was somewhat surprised to find many > > patterns when grepping llvm
> 6.0.0.
>
> *What are the considerations against sed-replacing all > > with >>?*
>
> Is it only the "don't fix it if it's not broken" consideration?
>

Generally - there's some aversion to messing with revision history (as much
as revision control systems can see through whitespace changes when
blaming, etc) & the like. (same reason we don't just clang-format the whole
codebase)

- Dave


> Thanks!
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20180820/0acb01c7/attachment.html>


More information about the cfe-dev mailing list