The Wrange-loop-analyses warns if a copy is made. Suppress this warning when a temporary is bound to a rvalue reference.
While fixing this issue also found a copy-paste error in test6, which is also fixed.
Depends on D68913
Paths
| Differential D71806
Improve Wrange-loop-analyses for rvalue reference ClosedPublic Authored by Mordante on Dec 22 2019, 7:05 AM.
Details Summary The Wrange-loop-analyses warns if a copy is made. Suppress this warning when a temporary is bound to a rvalue reference. While fixing this issue also found a copy-paste error in test6, which is also fixed. Depends on D68913
Diff Detail
Event TimelineThis revision is now accepted and ready to land.Dec 22 2019, 8:55 AM Closed by commit rGe5ab1e49f958: Improve Wrange-loop-analyses for rvalue reference (authored by Mordante). · Explain WhyJan 1 2020, 11:08 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 235782 clang/lib/Sema/SemaStmt.cpp
clang/test/SemaCXX/warn-range-loop-analysis.cpp
|