function uncast(node) {
  while (node.type === 'TypeCastExpression') {
    node = node.expression;
  }
  return node;
}
@fileoverview  Attempts to discover all state fields in a React component and
warn if any of them are never read.

State field definitions are collected from `this.state = {}` assignments in
the constructor, objects passed to `this.setState()`, and `state = {}` class
property assignments.