fix API : deal with the optional underscore
[babeltrace.git] / include / babeltrace / types.h
index cfc74a2f6206c72cfb3805bf139b81dbd0dba719..dd116f10ed49be0f42f32ccfcece918d20731502 100644 (file)
@@ -518,4 +518,13 @@ struct definition_enum *lookup_enum(struct definition *definition,
 struct definition *lookup_variant(struct definition *definition,
                                  const char *field_name);
 
+static inline
+const char *rem_(const char *str)
+{
+       if (str[0] == '_')
+               return &str[1];
+       else
+               return str;
+}
+
 #endif /* _BABELTRACE_TYPES_H */
This page took 0.030671 seconds and 4 git commands to generate.