xazax.hun added a comment.

We have `examples/analyzer-plugin`. I would prefer to add an example option to 
the example plugin so people do see how to do this when they are registering a 
checker from a plugin.



================
Comment at: include/clang/StaticAnalyzer/Checkers/Checkers.td:48
+    CmdLineOption<Boolean,
+                  "Optimistic",
+                  "In set to false, the checker assumes that it does not know "
----------------
Did you want to add this option to nullability? I believe it belongs to Malloc 
Checker.


================
Comment at: include/clang/StaticAnalyzer/Checkers/Checkers.td:49
+                  "Optimistic",
+                  "In set to false, the checker assumes that it does not know "
+                  "which functions might free the memory.",
----------------
`In` is a possible typo? `If` or `When`?


================
Comment at: include/clang/StaticAnalyzer/Checkers/Checkers.td:50
+                  "In set to false, the checker assumes that it does not know "
+                  "which functions might free the memory.",
+                  "false">,
----------------
Do we need `the`? Also, I think the checker also do not know the allocating 
functions. I think it might be better to describe the opposite. Optimistic 
means that the checker assumes all the allocating, deallocating functions are 
annotated.


================
Comment at: include/clang/StaticAnalyzer/Checkers/Checkers.td:384
+  CheckerOptions<[
+    CmdLineOption<Boolean,
+                  "Optimistic",
----------------
It would be great if there were a way to define options once and reuse them.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D57855/new/

https://reviews.llvm.org/D57855



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to