diff options
Diffstat (limited to 'tools/d2c/bits')
-rw-r--r-- | tools/d2c/bits/manager.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/d2c/bits/manager.c b/tools/d2c/bits/manager.c index cc2783b..edf682d 100644 --- a/tools/d2c/bits/manager.c +++ b/tools/d2c/bits/manager.c @@ -366,9 +366,12 @@ bool check_bits_correctness(const coding_bits *bits, int fd) bool define_used_bits_fields(const coding_bits *bits, int fd) { + bool got_one; /* Suit le nombre d'impressions*/ size_t i; /* Boucle de parcours */ raw_bitfield *rf; /* Accès confortable à un champ*/ + got_one = false; + for (i = 0; i < bits->bf_count; i++) { rf = &bits->fields[i]; @@ -376,8 +379,13 @@ bool define_used_bits_fields(const coding_bits *bits, int fd) dprintf(fd, "\t\traw_%s = (_raw >> %u) & 0x%llx;\n", rf->name, rf->start, (1ull << rf->length) - 1); + got_one = true; + } + if (got_one) + dprintf(fd, "\n"); + return true; } |