When comparing unqualified types, canonical types should be used, otherwise equivalent types may be treated as different type.
For example,
typedef int int_t;
generic int* a;
global int_t* b;
0 ? a : b should have type generic int*. However due to this bug, int_t and int are treated as different types, which causes the type of 0 ? a : b to have type generic void*.
This patch fixes it.