| 1 |
.. title:: clang-tidy - misc-unused-using-decls |
| 2 |
|
| 3 |
misc-unused-using-decls |
| 4 |
======================= |
| 5 |
|
| 6 |
Finds unused ``using`` declarations. |
| 7 |
|
| 8 |
Unused ``using``` declarations in header files will not be diagnosed since these |
| 9 |
using declarations are part of the header's public API. Allowed header file |
| 10 |
extensions can be configured via the global option `HeaderFileExtensions`. |
| 11 |
|
| 12 |
Example: |
| 13 |
|
| 14 |
.. code-block:: c++ |
| 15 |
|
| 16 |
// main.cpp |
| 17 |
namespace n { class C; } |
| 18 |
using n::C; // Never actually used. |