llvm-project/clang-tools-extra/docs
Adam Balogh 14dd073782 [Clang-Tidy] New check `bugprone-redundant-branch-condition`
Checking the same condition again in a nested `if` usually make no sense,
except if the value of the expression could have been changed between
the two checks. Although compilers may optimize this out, such code is
suspicious: the programmer may have meant to check something else.
Therefore it is worth to find such places in the code and notify the
user about the problem.

This patch implements a basic check for this problem. Currently it
only detects redundant conditions where the condition is a variable of
integral type. It also detects the possible bug if the variable is in an
//or// or //and// logical expression in the inner if and/or the variable
is in an //and// logical expression in the outer if statement. Negated
cases are not handled yet.

Differential Revision: https://reviews.llvm.org/D81272
2020-08-31 16:00:59 +02:00
..
_static Added more detailed documentation for clangd 2019-02-27 15:53:05 +00:00
_templates [clangd] Redirect documentation to clangd.llvm.org. 2020-03-12 11:45:40 +01:00
clang-tidy [Clang-Tidy] New check `bugprone-redundant-branch-condition` 2020-08-31 16:00:59 +02:00
clangd [clangd] Add README pointing to docs, bugtracker etc. NFC 2020-03-12 14:00:08 +01:00
CMakeLists.txt docs: Fix Sphinx detection with out-of-tree builds 2017-05-09 11:11:52 +00:00
ModularizeUsage.rst
README.txt Updated the documentation build instructions for the current CMake build system 2019-02-25 13:03:44 +00:00
ReleaseNotes.rst [Clang-Tidy] New check `bugprone-redundant-branch-condition` 2020-08-31 16:00:59 +02:00
clang-doc.rst doc: Document that extra-arg/extra-arg-before can be used several times 2019-12-24 13:07:08 +01:00
clang-include-fixer.rst [docs] Update path to clang-tools-extra 2020-01-02 19:30:29 +08:00
clang-modernize.rst
clang-rename.rst doc: use the right url to bugzilla 2020-03-22 22:49:40 +01:00
clang-tidy.rst [Documentation] Use HTTPS whenever possible. 2019-01-22 19:19:48 +00:00
clangd.rst [clangd] Redirect documentation to clangd.llvm.org. 2020-03-12 11:45:40 +01:00
conf.py Bump the trunk major version to 12 2020-07-15 12:05:05 +02:00
cpp11-migrate.rst
doxygen-mainpage.dox
doxygen.cfg.in [clang-tools-extra] NFC: Fix trivial typo in documents and comments 2020-04-05 15:28:40 +09:00
index.rst [clangd] Redirect documentation to clangd.llvm.org. 2020-03-12 11:45:40 +01:00
make.bat
modularize.rst [Documentation] Use HTTPS whenever possible. 2019-01-22 19:19:48 +00:00
pp-trace.rst [clang-tools-extra] NFC: Fix trivial typo in documents and comments 2020-04-05 15:28:40 +09:00

README.txt

----------------------------------
Documentation in clang-tools-extra
----------------------------------

To generate documentation in HTML format from files in clang-tools-extra/docs,
build the docs-clang-tools-html target.

To generate documentation from the source code using Doxygen, build the
doxygen-clang-tools target.