I think will be good idea to extend modernize-use-auto to cases when variable is assigned with cast, like: Type *Ptr1 = dynamic_cast<Type*>(Ptr2); Same could be done for LLVM casts.
https://reviews.llvm.org/D25316
Fixed by rL285579. (In reply to comment #0) > Same could be done for LLVM casts. Leaving for bug 26763.