presto-parser/src/main/java/io/prestosql/sql/tree/IntervalLiteral.java/IntervalLiteral/isYearToMonth
class IntervalLiteral:    public boolean isYearToMonth()
    {
        return startField == IntervalField.YEAR || startField == IntervalField.MONTH;
    }