================
@@ -206,23 +221,42 @@ class StdVariantChecker : public Checker<eval::Call, 
check::RegionChanges> {
     if (!ThisMemRegion)
       return;
 
+    // Get the first type alternative of the std::variant instance.
+    assert((ThisSVal.getType(C.getASTContext())->isPointerType() ||
+            ThisSVal.getType(C.getASTContext())->isReferenceType()) &&
+           "The This SVal must be a pointer!");
----------------
NagyDonat wrote:

```suggestion
           "The SVal representation of 'this' must be a pointer!");
```
Instead of capitalizing `this` (which deviates from its canonical style), use 
apostrophes to clarify that you're using it as the C++ keyword.

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

Reply via email to