================
@@ -133,6 +133,11 @@ 
UnusedReturnValueCheck::UnusedReturnValueCheck(llvm::StringRef Name,
                                             "::boost::system::error_code"))),
       AllowCastToVoid(Options.get("AllowCastToVoid", false)) {}
 
+UnusedReturnValueCheck::UnusedReturnValueCheck(llvm::StringRef Name,
----------------
bjosv wrote:

Added a constructor that initialized the (missing) CheckedReturnTypes and 
AllowCastToVoid, which is delegated to from the constructor that is used by the 
new checker.
Is this in line with your thoughts?

An alternative is to only have the constructor which sets all members, but I 
thought that looked a bit weird to set AllowCastToVoid twice when constructing 
IgnoredRemoveResultCheck, once when initializing the baseclass and secondly in 
the body to be able to use Options.get (which can't be called in the 
initialization list there).


https://github.com/llvm/llvm-project/pull/73119
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to