Skip to content

Commit

Permalink
Ensure that all static.fields-* files have contents
Browse files Browse the repository at this point in the history
For example, when adding and removing a struct named "z_test",
statics.fields-z.inc would not be touched after removing the struct because no
other structures were present in that file, which would cause the build to fail
because static.fields-z.inc still included "z_test.h".
  • Loading branch information
lethosor committed Dec 1, 2017
1 parent 3208cff commit 7961387
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions StructFields.pm
Original file line number Diff line number Diff line change
Expand Up @@ -614,4 +614,11 @@ sub emit_struct_fields($$;%) {
} 'fields-' . $fields_group;
}

for my $letter ('a' .. 'z') {
with_emit_static {
# make sure even empty files get overwritten
emit "";
} 'fields-' . $letter;
}

1;

0 comments on commit 7961387

Please sign in to comment.