integer->parent.declaration->id = CTF_TYPE_INTEGER;
integer->declaration.len = size;
integer->declaration.base = BT_CTF_INTEGER_BASE_DECIMAL;
- integer->declaration.encoding = BT_CTF_STRING_ENCODING_NONE;
+ integer->declaration.encoding =
+ (enum ctf_string_encoding) BT_CTF_STRING_ENCODING_NONE;
bt_ctf_field_type_init(&integer->parent, TRUE);
return &integer->parent;
}
}
integer = container_of(type, struct bt_ctf_field_type_integer, parent);
- ret = integer->declaration.encoding;
+ ret = (enum bt_ctf_string_encoding) integer->declaration.encoding;
end:
return ret;
}
}
integer = container_of(type, struct bt_ctf_field_type_integer, parent);
- integer->declaration.encoding = encoding;
+ integer->declaration.encoding = (enum ctf_string_encoding) encoding;
end:
return ret;
}
string->parent.declaration = &string->declaration.p;
string->parent.declaration->id = CTF_TYPE_STRING;
bt_ctf_field_type_init(&string->parent, TRUE);
- string->declaration.encoding = BT_CTF_STRING_ENCODING_UTF8;
+ string->declaration.encoding =
+ (enum ctf_string_encoding) BT_CTF_STRING_ENCODING_UTF8;
string->parent.declaration->alignment = CHAR_BIT;
return &string->parent;
}
string = container_of(type, struct bt_ctf_field_type_string,
parent);
- ret = string->declaration.encoding;
+ ret = (enum bt_ctf_string_encoding) string->declaration.encoding;
end:
return ret;
}
}
string = container_of(type, struct bt_ctf_field_type_string, parent);
- string->declaration.encoding = encoding;
+ string->declaration.encoding = (enum ctf_string_encoding) encoding;
end:
return ret;
}
"integer { size = %zu; align = %zu; signed = %s; encoding = %s; base = %s; byte_order = %s",
integer->declaration.len, type->declaration->alignment,
(integer->declaration.signedness ? "true" : "false"),
- get_encoding_string(integer->declaration.encoding),
+ get_encoding_string((enum bt_ctf_string_encoding) integer->declaration.encoding),
get_integer_base_string(integer->declaration.base),
get_byte_order_string(integer->declaration.byte_order));
if (integer->mapped_clock) {
g_string_append_printf(context->string,
"string { encoding = %s; }",
- get_encoding_string(string->declaration.encoding));
+ get_encoding_string((enum bt_ctf_string_encoding) string->declaration.encoding));
return 0;
}