[PATCH] [clang-tidy] Ignore expressions with incompatible deleters.

Alexander Kornienko alexfh at google.com
Wed Apr 8 05:36:56 PDT 2015


================
Comment at: clang-tidy/misc/UniqueptrResetReleaseCheck.cpp:52
@@ +51,3 @@
+  const auto *RightDeleter = getDeleterForUniquePtr(Result, "right_class");
+  if (!LeftDeleter || !RightDeleter)
+    return false;
----------------
sbenza wrote:
> alexfh wrote:
> > Can this only happen if unique_ptr is defined in a nonstandard way?
> The deleter could be a function pointer.
Ah, I see. But then we can also check if the function pointers are compatible and allow the fix, can't we?

http://reviews.llvm.org/D8422

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the cfe-commits mailing list