Visitor pattern for IF bugs