function isReference(node, parent) {
  return node.type === 'Identifier' &&
    !isFunctionName(node, parent) &&
    !isFunctionParameter(node, parent) &&
    !isDeclaredVariable(node, parent) &&
    !isPropertyInMemberExpression(node, parent) &&
    !isPropertyInObjectLiteral(node, parent);
}
True when node is reference to a variable.

That is it's an identifier, that's not used:

- as function name in function declaration/expression,
- as parameter name in function declaration/expression,
- as declared variable name in variable declaration,
- as object property name in member expression.
- as object property name in object literal.

@param {Object} node
@param {Object} parent Immediate parent node (to determine context)
@return {Boolean}