Simplify condition.
[cparser] / types.h
diff --git a/types.h b/types.h
index debdfef..690e683 100644 (file)
--- a/types.h
+++ b/types.h
@@ -3,6 +3,8 @@
 
 #include "type.h"
 
+extern type_t *type_error_type;
+
 extern type_t *type_char;
 extern type_t *type_double;
 extern type_t *type_float;
@@ -41,4 +43,6 @@ extern type_t *type_wchar_t_ptr;
 
 void init_basic_types(void);
 
+#define is_type_valid(type) ((type)->kind != TYPE_ERROR)
+
 #endif