| 32 | } |
| 33 | |
| 34 | bool CompileConstantFilter::isOffsetOfExpr(const ASTDefNode &Node) const { |
| 35 | const auto *Assigned = Node.getAssigned(); |
| 36 | if (!Assigned) |
| 37 | return false; |
| 38 | |
| 39 | const auto *E = dyn_cast_or_null<Expr>(Assigned->getNode().get<Expr>()); |
| 40 | if (!E) |
| 41 | return false; |
| 42 | |
| 43 | return dyn_cast_or_null<OffsetOfExpr>(E->IgnoreCasts()); |
| 44 | } |
| 45 | |
| 46 | } // namespace ftg |
nothing calls this directly
no test coverage detected