[cfe-dev] clang-tidy and 3.7 release notes

Alexander Kornienko via cfe-dev cfe-dev at lists.llvm.org
Tue Aug 18 10:14:33 PDT 2015


On Mon, Aug 17, 2015 at 6:53 PM, Hans Wennborg <hans at chromium.org> wrote:

> I figured in Clang's release notes, docs/ReleaseNotes.rst on the 3.7
> branch:
> http://llvm.org/viewvc/llvm-project/cfe/branches/release_37/docs/ReleaseNotes.rst?view=log
>
> If you don't want to check out the branch, you can also just send me
> some text and I'll commit it.
>


OK, clang-tidy summary of changes from 3.6.2 final:

Added new checks:
  * google-global-names-in-headers: flag global namespace pollution in
header files.
  * misc-assert-side-effect: detects `assert()` conditions with side
effects which can cause different behavior in debug / release builds.
  * misc-assign-operator-signature: finds declarations of assign operators
with the wrong return and/or argument types.
  * misc-inaccurate-erase: warns when some elements of a container are not
removed due to using the `erase()` algorithm incorrectly.
  * misc-inefficient-algorithm: warns on inefficient use of STL algorithms
on associative containers.
  * misc-macro-parentheses: finds macros that can have unexpected behavior
due to missing parentheses.
  * misc-macro-repeated-side-effects: checks for repeated argument with
side effects in macros.
  * misc-noexcept-move-constructor: flags user-defined move constructors
and assignment operators not marked with `noexcept` or marked with
`noexcept(expr)` where `expr` evaluates to `false` (but is not a `false`
literal itself).
  * misc-static-assert: replaces `assert()` with `static_assert()` if the
condition is evaluatable at compile time.
  * readability-container-size-empty: checks whether a call to the `size()`
method can be replaced with a call to `empty()`.
  * readability-else-after-return: flags conditional statements having the
`else` branch, when the `true` branch has a `return` as the last statement.
  * readability-redundant-string-cstr: finds unnecessary calls to
`std::string::c_str()`.
  * readability-shrink-to-fit: replaces copy and swap tricks on shrinkable
containers with the `shrink_to_fit()` method call.
  * readability-simplify-boolean-expr: looks for boolean expressions
involving boolean constants and simplifies them to use the appropriate
boolean expression directly (`if (x == true) ... -> if (x)`, etc.)

+ minor fixes and improvements



>
> Thanks,
> Hans
>
> On Sun, Aug 16, 2015 at 7:04 PM, Alexander Kornienko <alexfh at google.com>
> wrote:
> > I'll try to come up with a short summary. Where exactly should the text
> go?
> >
> > -- Alex
> >
> > On 14 Aug 2015 20:22, "Hans Wennborg" <hans at chromium.org> wrote:
> >>
> >> Hi,
> >>
> >> It was pointed out to me that there's been a bunch of work on new
> >> checkers, but there's no mention of this in the 3.7 release notes.
> >>
> >> Would someone be willing to write something about this?
> >>
> >> Cheers,
> >> Hans
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20150818/16d0a5c4/attachment.html>


More information about the cfe-dev mailing list