the "Capture" struct is now a class

This commit is contained in:
Vern Paxson 2023-06-16 15:30:52 -07:00 committed by Arne Welzel
parent 528aa6766a
commit b6464814c9
6 changed files with 24 additions and 8 deletions

View file

@ -4726,7 +4726,7 @@ bool LambdaExpr::CheckCaptures(StmtPtr when_parent)
for ( const auto& c : *captures )
{
auto cid = c.id.get();
auto cid = c.Id().get();
if ( ! cid )
// This happens for undefined/inappropriate
@ -4768,7 +4768,7 @@ bool LambdaExpr::CheckCaptures(StmtPtr when_parent)
for ( const auto& c : *captures )
{
auto cid = c.id.get();
auto cid = c.Id().get();
if ( cid && capture_is_matched.count(cid) == 0 )
{
auto msg = util::fmt("%s is captured but not used inside %s", cid->Name(), desc);