ccotter added a comment.

Thanks, fixed the first false positive example you gave. Let me think about the 
second example in your most recent post:

  char c = '\n';
  using Size = int;
  Size size = 10U;
  std::string str2(c, size);

This is my newly added case `swapped4`, where one of my original intents was to 
flag this code as "swapped."  I can see the the ambiguity. Worst case, 
"confusing string fill constructor arguments" is the fallback that I think is 
acceptable, and still achieves the goal of at least flagging the code as 
potentially buggy.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D143971

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

Reply via email to