You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (m_currentScope->GetScopeType() == ScopeType_Parameter
8382
-
|| (m_currentScope->GetScopeType() == ScopeType_Block && m_currentScope->GetEnclosingScope()->GetScopeType() == ScopeType_Parameter)) // Check whether this is a class definition inside param scope
8381
+
if(m_currentScope->AncestorScopeIsParameter()) // Yield is not allowed within any parameter scope
8383
8382
{
8384
8383
Error(ERRsyntax);
8385
8384
}
8386
8385
}
8387
8386
elseif (nop == knopAwait)
8388
8387
{
8389
8388
if (!this->GetScanner()->AwaitIsKeywordRegion() ||
(m_currentScope->GetScopeType() == ScopeType_Block && m_currentScope->GetEnclosingScope()->GetScopeType() == ScopeType_Parameter)) // Check whether this is a class definition inside param scope
8389
+
m_currentScope->AncestorScopeIsParameter()) // Await is not allowed within any parameter scope
8392
8390
{
8393
8391
// As with the 'yield' keyword, the case where 'await' is scanned as a keyword (tkAWAIT)
8394
8392
// but the scanner is not treating await as a keyword (!this->GetScanner()->AwaitIsKeyword())
0 commit comments