diff options
author | Erick Ochoa <erick.ochoa@theobroma-systems.com> | 2020-05-28 10:07:29 +0200 |
---|---|---|
committer | Erick Ochoa <erick.ochoa@theobroma-systems.com> | 2020-05-28 10:07:29 +0200 |
commit | fe1741a4a31cd2d5b430d53322f886865ede5787 (patch) | |
tree | 209f67ebab420910ca1e11cf9c8acd3af4d66d71 /gcc/compare-types.h | |
parent | 2117ebc711d83376589e8e08d16ed7dadc869a16 (diff) |
comparison weird case
Diffstat (limited to 'gcc/compare-types.h')
-rw-r--r-- | gcc/compare-types.h | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/gcc/compare-types.h b/gcc/compare-types.h index 2c690fc3081..384819ce2d7 100644 --- a/gcc/compare-types.h +++ b/gcc/compare-types.h @@ -1,11 +1,18 @@ #pragma once + namespace test_type_equality { void run_tests(); }; -extern bool eq_identifier(const_tree a, const_tree b); -extern bool eq_pointer(const_tree a, const_tree b); -extern bool eq_main_variant(const_tree a, const_tree b); -extern bool eq_canonical(const_tree a, const_tree b); -extern bool eq_canonical_internal(const_tree a, const_tree b); -extern bool eq_type_compare(const_tree a, const_tree b); -extern bool eq_type_structural(const_tree a, const_tree b); -extern bool eq_types(const_tree a, const_tree b, const bool force_structural = false); + +static constexpr unsigned not_equal = 0; +static constexpr unsigned equal_incomplete = 1 << 1; +// equal should be the last one +static constexpr unsigned equal = 1 << 2; + +extern unsigned eq_identifier(const_tree a, const_tree b); +extern unsigned eq_pointer(const_tree a, const_tree b); +extern unsigned eq_main_variant(const_tree a, const_tree b); +extern unsigned eq_canonical(const_tree a, const_tree b); +extern unsigned eq_canonical_internal(const_tree a, const_tree b); +extern unsigned eq_type_compare(const_tree a, const_tree b); +extern unsigned eq_type_structural(const_tree a, const_tree b); +extern unsigned eq_types(const_tree a, const_tree b, const bool force_structural = false); |