| 295 | //----------------------------------------------------------------------------- |
| 296 | |
| 297 | const QualType GetDesugarType(const QualType& QT) |
| 298 | { |
| 299 | if(QT.getTypePtrOrNull()) { |
| 300 | if(const auto* autoType = QT->getAs<clang::AutoType>(); autoType and autoType->isSugared()) { |
| 301 | const auto dt = autoType->getDeducedType(); |
| 302 | |
| 303 | if(const auto* et = dt->getAs<ElaboratedType>()) { |
| 304 | return et->getNamedType(); |
| 305 | } else { |
| 306 | return dt; |
| 307 | } |
| 308 | |
| 309 | } else if(auto declType = QT->getAs<clang::DecltypeType>()) { |
| 310 | return declType->desugar(); |
| 311 | } |
| 312 | } |
| 313 | return QT; |
| 314 | } |
| 315 | //----------------------------------------------------------------------------- |
| 316 | |
| 317 | static const VarDecl* GetVarDeclFromDeclRefExpr(const DeclRefExpr& declRefExpr) |
no outgoing calls
no test coverage detected