================ @@ -313,6 +232,9 @@ class StreamChecker : public Checker<check::PreCall, eval::Call, BugType BT_ResourceLeak{this, "Resource leak", "Stream handling error", /*SuppressOnSink =*/true}; + const char *FeofNote = "Assuming stream reaches end-of-file here"; + const char *FerrorNote = "Assuming this stream operation fails"; ---------------- NagyDonat wrote:
It's a bit strange that these constants are non-static data members of the singleton `StreamChecker` object (so they're accessed through the captured `this` in lambdas); perhaps consider declaring them as static variables. Independently, consider declaring these string constants as `std::string` because they will be converted to `std::string` when they're used. https://github.com/llvm/llvm-project/pull/83288 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits