def resolveSpecTypeCombos(t1, t2):
    """Resolve Quantity and QuantSpec types when combined.
     QuantSpec <op> QuantSpec -> specType rules:
     same types -> that type
     ExpFuncSpec o RHSfuncSpec -> RHSfuncSpec
     ImpFuncSpec o RHSfuncSpec -> RHSfuncSpec (should this be an error?)
     ImpFuncSpec o ExpFuncSpec -> ImpFuncSpec"""
    if t1=='RHSfuncSpec' or t2=='RHSfuncSpec':
        return 'RHSfuncSpec'
    elif t1=='ImpFuncSpec' or t2=='ImpFuncSpec':
        return 'ImpFuncSpec'
    else:
        return 'ExpFuncSpec'