[cfe-dev] Clang-format ideas

Daniel Jasper djasper at google.com
Sun Oct 13 11:54:49 PDT 2013


On Sun, Oct 13, 2013 at 11:43 AM, Kim Gräsman <kim.grasman at gmail.com> wrote:

> On Fri, Oct 11, 2013 at 9:02 PM, Daniel Jasper <djasper at google.com> wrote:
> >
> >> The namespace declaration style may be more work, so I'll see if I can
> >> find some time to figure it out once I'm better acquainted with the
> >> code base.
> >
> >
> > I would guess that this change is much lower value. Usually you would use
> > clang-format mostly within editors or on patches that you create and
> these
> > will rarely contain the namespace declarations. If they do, it is a
> matter
> > of hitting "J" a few times in vim ;-).
>
> We're considering running clang-format in batch over our entire
> codebase, so we're coming at this from a slightly different angle.
>

Well, that would also be a good opportunity to get rid of this particular
coding style ;-)..

Slightly more serious, I am all for preserving vertical space as I think it
does matter how much code fits onto a display page. However, such namespace
declarations are almost always in irrelevant parts of the file and the gain
of putting them all in one line is really small.

Cheers,
Daniel

I'll see if I can come up with a concrete patch at some point, and
> we'll see what the impact is like.
>
> - Kim
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20131013/5779a4dd/attachment.html>


More information about the cfe-dev mailing list