grigorypas wrote:
@mizvekov Could you please merge if it is good to go? I don't have write
access.
https://github.com/llvm/llvm-project/pull/139973
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinf
https://github.com/grigorypas created
https://github.com/llvm/llvm-project/pull/139973
This PR aims at adding warning similar to the one in GCC (-Wnrvo) that targets
missed opportunities for Named Return Value Optimization (NRVO). The warning is
not enabled by default.
cc: @WenleiHe
https://github.com/grigorypas updated
https://github.com/llvm/llvm-project/pull/139973
Rate limit ยท GitHub
body {
background-color: #f6f8fa;
color: #24292e;
font-family: -apple-system,BlinkMacSystemFont,Segoe
UI,Helvetica,Arial,san
grigorypas wrote:
> Can you also include a few tests which show whether we suppress the warning
> on disabled branches of an 'if constexpr'?
>
> Beware we also have bugs and odd cases in this area:
>
> * It should be possible to NRVO a variable which you don't actually return,
> by retuning i