Move #define outside of max_type for clarity

This commit is contained in:
Tim Wojtulewicz 2019-05-29 20:07:30 -07:00
parent 6860d5b083
commit 7243292136

View file

@ -2123,6 +2123,10 @@ int is_assignable(BroType* t)
return 0;
}
#define CHECK_TYPE(t) \
if ( t1 == t || t2 == t ) \
return t;
TypeTag max_type(TypeTag t1, TypeTag t2)
{
if ( t1 == TYPE_INTERVAL || t1 == TYPE_TIME )
@ -2132,10 +2136,6 @@ TypeTag max_type(TypeTag t1, TypeTag t2)
if ( BothArithmetic(t1, t2) )
{
#define CHECK_TYPE(t) \
if ( t1 == t || t2 == t ) \
return t;
CHECK_TYPE(TYPE_DOUBLE);
CHECK_TYPE(TYPE_INT);
CHECK_TYPE(TYPE_COUNT);