function createLiteralTypeAnnotation (path: NodePath): ?TypeAnnotation {
    let annotation;
    if (path.isStringLiteral()) {
      annotation = t.stringLiteralTypeAnnotation();
    }
    else if (path.isNumericLiteral()) {
      annotation = t.numericLiteralTypeAnnotation();
    }
    else if (path.isBooleanLiteral()) {
      annotation = t.booleanLiteralTypeAnnotation();
    }
    else {
      return path.getTypeAnnotation();
    }
    annotation.value = path.node.value;
    return annotation;
  }
Get the type annotation for a given node.