core: Export tag__natural_alignment()

We'll use it in the BTF loader.

Signed-off-by: Douglas Raillard <douglas.raillard@arm.com>
[ Split from a larger patch ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
Douglas Raillard 2021-10-18 14:16:21 +01:00 committed by Arnaldo Carvalho de Melo
parent 43e8216c25
commit 4db65fe0cd
2 changed files with 3 additions and 1 deletions

View File

@ -1515,7 +1515,7 @@ void class__find_holes(struct class *class)
static size_t type__natural_alignment(struct type *type, const struct cu *cu);
static size_t tag__natural_alignment(struct tag *tag, const struct cu *cu)
size_t tag__natural_alignment(struct tag *tag, const struct cu *cu)
{
size_t natural_alignment = 1;

View File

@ -1007,6 +1007,8 @@ struct type {
void __type__init(struct type *type);
size_t tag__natural_alignment(struct tag *tag, const struct cu *cu);
static inline struct class *type__class(const struct type *type)
{
return (struct class *)type;