Skip to content

Commit f205962

Browse files
committed
enabled and fixed modernize-use-using clang-tidy warnings
1 parent 5b736f2 commit f205962

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

.clang-tidy

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ Checks: >
3737
-modernize-use-default-member-init,
3838
-modernize-use-nodiscard,
3939
-modernize-use-trailing-return-type,
40-
-modernize-use-using,
4140
-readability-avoid-nested-conditional-operator,
4241
-readability-braces-around-statements,
4342
-readability-function-cognitive-complexity,

simplecpp.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ namespace simplecpp {
6868
/** C++ code standard */
6969
enum cppstd_t { CPPUnknown=-1, CPP03, CPP11, CPP14, CPP17, CPP20, CPP23, CPP26 };
7070

71-
typedef std::string TokenString;
71+
using TokenString = std::string;
7272
class Macro;
7373
class FileDataCache;
7474

@@ -221,7 +221,7 @@ namespace simplecpp {
221221
std::string msg;
222222
};
223223

224-
typedef std::list<Output> OutputList;
224+
using OutputList =std::list<Output>;
225225

226226
/** List of tokens. */
227227
class SIMPLECPP_LIB TokenList {
@@ -439,10 +439,10 @@ namespace simplecpp {
439439
mData.clear();
440440
}
441441

442-
typedef std::vector<std::unique_ptr<FileData>> container_type;
443-
typedef container_type::iterator iterator;
444-
typedef container_type::const_iterator const_iterator;
445-
typedef container_type::size_type size_type;
442+
using container_type = std::vector<std::unique_ptr<FileData>>;
443+
using iterator = container_type::iterator;
444+
using const_iterator = container_type::const_iterator;
445+
using size_type = container_type::size_type;
446446

447447
size_type size() const {
448448
return mData.size();

0 commit comments

Comments
 (0)