ent->allocation = al;
}
+/* return the name of the visibility */
+const char *get_allocation_name(ent_allocation all)
+{
+#define X(a) case a: return #a
+ switch (all) {
+ X(automatic_allocated);
+ X(parameter_allocated);
+ X(dynamic_allocated);
+ X(static_allocated);
+ default: return "BAD VALUE";
+ }
+#undef X
+}
+
INLINE ent_visibility
get_entity_visibility (entity *ent) {
ent->visibility = vis;
}
+/* return the name of the visibility */
+const char *get_visibility_name(ent_visibility vis)
+{
+#define X(a) case a: return #a
+ switch (vis) {
+ X(local);
+ X(external_visible);
+ X(external_allocated);
+ default: return "BAD VALUE";
+ }
+#undef X
+}
+
INLINE ent_variability
get_entity_variability (entity *ent) {
return ent->variability;
/** Sets the allocation type of an entity. */
void set_entity_allocation (entity *ent, ent_allocation al);
+/** Return the name of the visibility */
+const char *get_allocation_name(ent_allocation vis);
+
/**
* This enumeration flags the visibility of entities. This is necessary
* for partial compilation.
/** Sets the visibility of an entity. */
void set_entity_visibility (entity *ent, ent_visibility vis);
+/** Return the name of the visibility */
+const char *get_visibility_name(ent_visibility vis);
+
/** This enumeration flags the variability of entities. */
typedef enum {
uninitialized, /**< The content of the entity is completely unknown. */