Skip to content
Snippets Groups Projects
Commit 739c8bfb authored by Henrik (Grubba) Grubbström's avatar Henrik (Grubba) Grubbström
Browse files

Compiler [Typechecker]: Or-ing a type and its inverse yields mixed.

parent 3d1389a0
No related branches found
No related tags found
No related merge requests found
...@@ -2779,6 +2779,10 @@ static int lower_or_pike_types(struct pike_type *t1, ...@@ -2779,6 +2779,10 @@ static int lower_or_pike_types(struct pike_type *t1,
t = t2; t = t2;
} else if (zero_implied && (t2->type == T_ZERO)) { } else if (zero_implied && (t2->type == T_ZERO)) {
t = t1; t = t1;
} else if ((t1->type == T_NOT) && pike_types_le(t1->car, t2)) {
t = mixed_type_string;
} else if ((t2->type == T_NOT) && pike_types_le(t2->car, t1)) {
t = mixed_type_string;
} else if ((t1->type ^ '0') < (t2->type ^ '0')) { } else if ((t1->type ^ '0') < (t2->type ^ '0')) {
/* Note: Adjusted order to get markers first. */ /* Note: Adjusted order to get markers first. */
t = t1; t = t1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment