Preprocessor:addCommentHandler() does not take ownership, so we'd end up leaking the TodoCommentHandler.
This patch makes it owned by the Check object.
Differential D5402
[clang-tidy] Don't leak the TodoCommentHandler object hans on Sep 18 2014, 10:56 AM. Authored by
Details Preprocessor:addCommentHandler() does not take ownership, so we'd end up leaking the TodoCommentHandler. This patch makes it owned by the Check object.
Diff Detail
Event TimelineComment Actions Yikes, another API with non-obvious ownership semantics. Thanks for catching this. Patch looks good.
|