code: function validateCompatibleTypes(startPos, endPos, x, y) {
    if (joinTypes(x.type(), y.type()) === null) {
      fail(startPos, endPos,
        'expected-values-to-have-compatible-types', [
          x.type(),
          y.type(),
        ]
      );
    }
  }
docs: /* Validate that the types of 'x' and 'y' are compatible