[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-14 Thread Matthias Gehre via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL368929: [LifetimeAnalysis] Support std::stack::top() and std::optional::value() (authored by mgehre, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre updated this revision to Diff 214954. mgehre marked an inline comment as done. mgehre added a comment. Add tests for rvalue-ref overloads Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66164/new/ https://reviews.llvm.org/D66164 Files:

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre marked 3 inline comments as done. mgehre added inline comments. Comment at: clang/lib/Sema/SemaInit.cpp:6583 .Cases("end", "rend", "cend", "crend", true) -.Cases("c_str", "data", "get", true) +.Cases("c_str", "data", "get", "value", true)

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre updated this revision to Diff 214950. mgehre marked 2 inline comments as done. mgehre added a comment. Fix commit Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66164/new/ https://reviews.llvm.org/D66164 Files: clang/lib/Sema/SemaInit.cpp

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/test/Sema/warn-lifetime-analysis-nocfg.cpp:172 T *(); + T (); +}; mgehre wrote: > xazax.hun wrote: > > I actually was a bit lazy when I added these tests. Both `value` and > > `operator*` is overloaded on

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre marked an inline comment as done. mgehre added inline comments. Comment at: clang/test/Sema/warn-lifetime-analysis-nocfg.cpp:172 T *(); + T (); +}; xazax.hun wrote: > I actually was a bit lazy when I added these tests. Both `value` and > `operator*`

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/Sema/SemaInit.cpp:6583 .Cases("end", "rend", "cend", "crend", true) -.Cases("c_str", "data", "get", true) +.Cases("c_str", "data", "get", "value", true) // Map and set types.

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added a comment. This revision is now accepted and ready to land. Herald added a subscriber: rnkovacs. LG! But let's wait for Dmitri :) Comment at: clang/test/Sema/warn-lifetime-analysis-nocfg.cpp:172 T *(); + T (); +};

[PATCH] D66164: [LifetimeAnalysis] Support std::stack::top() and std::optional::value()

2019-08-13 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre created this revision. mgehre added a reviewer: gribozavr. Herald added a project: clang. Diagnose dangling pointers that come from std::stack::top() and std::optional::value(). Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D66164 Files: clang/lib/Sema/SemaInit.cpp