function getConfigForFunction(node){if(node.type==="ArrowFunctionExpression"){// Always ignore non-async functions and arrow functions without parens, e.g. async foo => bar
if(node.async&&astUtils.isOpeningParenToken(sourceCode.getFirstToken(node,{skip:1}))){// For backwards compatibility, the base config does not apply to async arrow functions.
return overrideConfig.asyncArrow||"ignore";}}else if(isNamedFunction(node)){return overrideConfig.named||baseConfig;// `generator-star-spacing` should warn anonymous generators. E.g. `function* () {}`
}else if(!node.generator){return overrideConfig.anonymous||baseConfig;}return"ignore";}
Gets the config for a given function
@param {ASTNode} node The function node
@returns {string} "always", "never", or "ignore"