Assert that no typerefs are passed to get_unqualified_type().
authorChristoph Mallon <christoph.mallon@gmx.de>
Mon, 15 Sep 2008 13:12:28 +0000 (13:12 +0000)
committerChristoph Mallon <christoph.mallon@gmx.de>
Mon, 15 Sep 2008 13:12:28 +0000 (13:12 +0000)
[r21968]

type.c

diff --git a/type.c b/type.c
index 99c73a9..c55b777 100644 (file)
--- a/type.c
+++ b/type.c
@@ -747,6 +747,8 @@ type_t *duplicate_type(const type_t *type)
  */
 type_t *get_unqualified_type(type_t *type)
 {
+       assert(!is_typeref(type));
+
        if (type->base.qualifiers == TYPE_QUALIFIER_NONE)
                return type;