private static Context getContextForArrowFunctionBody ( Context context ) { return context . inForInInitClause ( ) ? Context . START_OF_ARROW_FN_IN_FOR_INIT : Context . START_OF_ARROW_FN_BODY ; }
If we re at the start of an arrow function body we need parentheses around object literals and object patterns . We also must also pass the IN_FOR_INIT_CLAUSE flag into subexpressions .