summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/docs
diff options
context:
space:
mode:
authorJonas Toth <jonas.toth@gmail.com>2018-10-05 13:36:00 +0000
committerJonas Toth <jonas.toth@gmail.com>2018-10-05 13:36:00 +0000
commitd0794365710a85f3c8c4f9847c80eddace29d954 (patch)
tree8d08af9296572ef156d98a20792871b78a208709 /clang-tools-extra/docs
parent149de8de19064a599c64975b3b218e7ce5f2aaa3 (diff)
downloadbcm5719-llvm-d0794365710a85f3c8c4f9847c80eddace29d954.tar.gz
bcm5719-llvm-d0794365710a85f3c8c4f9847c80eddace29d954.zip
[clang-tidy] Replace deprecated std::ios_base aliases
This check warns the uses of the deprecated member types of std::ios_base and replaces those that have a non-deprecated equivalent. Patch by andobence! Reviewd by: alexfh Revision ID: https://reviews.llvm.org/D51332 llvm-svn: 343848
Diffstat (limited to 'clang-tools-extra/docs')
-rw-r--r--clang-tools-extra/docs/ReleaseNotes.rst6
-rw-r--r--clang-tools-extra/docs/clang-tidy/checks/list.rst1
-rw-r--r--clang-tools-extra/docs/clang-tidy/checks/modernize-deprecated-ios-base-aliases.rst17
3 files changed, 24 insertions, 0 deletions
diff --git a/clang-tools-extra/docs/ReleaseNotes.rst b/clang-tools-extra/docs/ReleaseNotes.rst
index 386c74e7a81..9da5ce6e916 100644
--- a/clang-tools-extra/docs/ReleaseNotes.rst
+++ b/clang-tools-extra/docs/ReleaseNotes.rst
@@ -99,6 +99,12 @@ Improvements to clang-tidy
Checks for uses of nested namespaces in the form of
``namespace a { namespace b { ... }}`` and offers change to
syntax introduced in C++17 standard: ``namespace a::b { ... }``.
+
+- New :doc:`modernize-deprecated-ios-base-aliases
+ <clang-tidy/checks/modernize-deprecated-ios-base-aliases>` check.
+
+ This check warns the uses of the deprecated member types of ``std::ios_base``
+ and replaces those that have a non-deprecated equivalent.
- New :doc:`readability-magic-numbers
<clang-tidy/checks/readability-magic-numbers>` check.
diff --git a/clang-tools-extra/docs/clang-tidy/checks/list.rst b/clang-tools-extra/docs/clang-tidy/checks/list.rst
index 4180385fea9..cc966a9b07a 100644
--- a/clang-tools-extra/docs/clang-tidy/checks/list.rst
+++ b/clang-tools-extra/docs/clang-tidy/checks/list.rst
@@ -174,6 +174,7 @@ Clang-Tidy Checks
modernize-avoid-bind
modernize-concat-nested-namespaces
modernize-deprecated-headers
+ modernize-deprecated-ios-base-aliases
modernize-loop-convert
modernize-make-shared
modernize-make-unique
diff --git a/clang-tools-extra/docs/clang-tidy/checks/modernize-deprecated-ios-base-aliases.rst b/clang-tools-extra/docs/clang-tidy/checks/modernize-deprecated-ios-base-aliases.rst
new file mode 100644
index 00000000000..9460cab3576
--- /dev/null
+++ b/clang-tools-extra/docs/clang-tidy/checks/modernize-deprecated-ios-base-aliases.rst
@@ -0,0 +1,17 @@
+.. title:: clang-tidy - modernize-deprecated-ios-base-aliases
+
+modernize-deprecated-ios-base-aliases
+=====================================
+
+This check warns the uses of the deprecated member types of ``std::ios_base``
+and replaces those that have a non-deprecated equivalent.
+
+=================================== ===========================
+Deprecated member type Replacement
+=================================== ===========================
+``std::ios_base::io_state`` ``std::ios_base::iostate``
+``std::ios_base::open_mode`` ``std::ios_base::openmode``
+``std::ios_base::seek_dir`` ``std::ios_base::seekdir``
+``std::ios_base::streamoff``
+``std::ios_base::streampos``
+=================================== ===========================
OpenPOWER on IntegriCloud