wyt added inline comments.

================
Comment at: clang/include/clang/Analysis/FlowSensitive/CFGMatchSwitch.h:55
+                                        MSActionT<NodeT, State, Result> A) && {
+    std::move(std::move(StmtBuilder).template CaseOf<NodeT>(M, A));
+    return std::move(*this);
----------------
sgatev wrote:
> Is the outer move necessary? Also, aren't we supposed to assign the result 
> back to `StmtBuilder`? Same comment for `InitBuilder` below.
> Is the outer move necessary? Also, aren't we supposed to assign the result 
> back to StmtBuilder? Same comment for InitBuilder below.

Yeap the outer move was unnecessary.
The self-assignment wasn't necessary since the CaseOf modifies the object it is 
called on, in fact the self-assignment led to the destroyal of contents inside 
the builder.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D131616

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

Reply via email to