[ITK-dev] Clang scripting to make code changes

Johnson, Hans J hans-johnson at uiowa.edu
Sat Sep 10 07:26:49 EDT 2016


I use clang tidy.  

I have not written any custom filters.

Sent from my iPhone

> On Sep 9, 2016, at 12:18 PM, Lowekamp, Bradley (NIH/NLM/LHC) [C] <blowekamp at mail.nih.gov> wrote:
> 
> Hans,
> 
> If I recall correctly you have used a clang based tool to make context based changes on ITK code before.
> 
> To addresses some dynamic_cast failures which can occur with Xcode based tools, we are considering the patch to change dynamic_cast to Object::SafeDownCast[1]. One issue is finding a good way to to update dynamic_casts.
> 
> With the clang based tool can we change “dynamic_cast<TObject>(arg)” to “TObject::SafeDownCast(arg)” only if TObject has itk::LightObject as some ancestor class?
> 
> Thanks,
> Brad
> 
> [1] http://review.source.kitware.com/#/c/21499/


More information about the Insight-developers mailing list