diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-07-08 16:46:57 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-07-08 16:47:31 +0200 |
commit | 9d80c032febaaf72b0991ea7add30af506af820a (patch) | |
tree | eedc2fd2ea68b85f96d2400312f43af57a28a922 /compilerplugins/clang/check.cxx | |
parent | 1257344e89e80715c35e621b7693f401f147bdf1 (diff) |
loplugin:redundantcast: redundant static_casts
Change-Id: I4d50b77745d68a23136221ef06f327137e89fa7e
Diffstat (limited to 'compilerplugins/clang/check.cxx')
-rw-r--r-- | compilerplugins/clang/check.cxx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/compilerplugins/clang/check.cxx b/compilerplugins/clang/check.cxx index af9532620920..33be502c3e1c 100644 --- a/compilerplugins/clang/check.cxx +++ b/compilerplugins/clang/check.cxx @@ -67,6 +67,15 @@ TypeCheck TypeCheck::Pointer() const { return TypeCheck(); } +TypeCheck TypeCheck::Typedef() const { + if (!type_.isNull()) { + if (auto const t = type_->getAs<clang::TypedefType>()) { + return TypeCheck(t->desugar()); + } + } + return TypeCheck(); +} + TypeCheck TypeCheck::NotSubstTemplateTypeParmType() const { return (!type_.isNull() |