[patch, clang-format] Change the output of --version
Daniel Jasper
djasper at google.com
Tue Jan 7 00:02:13 PST 2014
Sounds like a good idea to me!
On Jan 7, 2014 6:55 AM, "Nico Weber" <thakis at chromium.org> wrote:
> Hi,
>
> `clang-format --version` currently uses llvm's default version formatter
> which looks like this:
>
> $ clang-format --version
> LLVM (http://llvm.org/):
> LLVM version 3.5svn
> Optimized build with assertions.
> Built Jan 3 2014 (14:28:46).
> Default target: x86_64-apple-darwin13.0.0
> Host CPU: core-avx-i
>
> This includes all kinds of stuff that's not interesting for a code
> formatter, and it lacks the revision clang-format was built at. In
> comparison, `clang --version` prints
>
> $ bin/clang --version
> clang version 3.5 (198452)
> Target: x86_64-apple-darwin13.0.0
> Thread model: posix
>
> which I think is much better (but Target: and arguably Thread model:
> aren't interesting for a formatter either).
>
> The attached patch changes the output of `clang-format --version` to be
> just
>
> $ bin/clang-format --version
> clang-format version 3.5 (198452)
>
> The part I care about most is including the revision number.
>
> Ok?
>
> Nico
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140107/31490419/attachment.html>
More information about the cfe-commits
mailing list