diff options
author | David Garcia Quintas <dgq@google.com> | 2015-10-06 11:05:05 -0700 |
---|---|---|
committer | David Garcia Quintas <dgq@google.com> | 2015-10-06 11:05:05 -0700 |
commit | 35284f0c8442ae31dc9057583d2064c5257fae4f (patch) | |
tree | 0ad8f44503df9b00f24f97ab8502839d90834811 /tools/codegen | |
parent | 760cd88eafaa4098eae2ab8b3935ff8e398c9332 (diff) |
Simplified comments
Diffstat (limited to 'tools/codegen')
-rw-r--r-- | tools/codegen/core/gen_hpack_tables.c | 10 | ||||
-rw-r--r-- | tools/codegen/core/gen_legal_metadata_characters.c | 5 |
2 files changed, 6 insertions, 9 deletions
diff --git a/tools/codegen/core/gen_hpack_tables.c b/tools/codegen/core/gen_hpack_tables.c index 48398bebd5..bae4e4cd73 100644 --- a/tools/codegen/core/gen_hpack_tables.c +++ b/tools/codegen/core/gen_hpack_tables.c @@ -73,9 +73,8 @@ static unsigned char prefix_mask(unsigned char prefix_len) { for (i = 0; i < prefix_len; i++) { /* NB: the following integer arithmetic operation needs to be in its * expanded form due to the "integral promotion" performed (see section - * 3.2.1.1 of the C89 draft standard), which in this case upcasts the result - * of the bitwise OR to "unsigned". A cast to the smaller container type is - * then required to avoid the compiler warning */ + * 3.2.1.1 of the C89 draft standard). A cast to the smaller container type + * is then required to avoid the compiler warning */ out = (unsigned char)(out | (unsigned char)(1 << (7 - i))); } return out; @@ -99,9 +98,8 @@ static void generate_first_byte_lut(void) { if ((prefix_mask(fields[j].prefix_length) & i) == fields[j].prefix) { /* NB: the following integer arithmetic operation needs to be in its * expanded form due to the "integral promotion" performed (see section - * 3.2.1.1 of the C89 draft standard), which in this case upcasts the - * result of the bitwise AND to "unsigned". A cast to the smaller - * container type is then required to avoid the compiler warning */ + * 3.2.1.1 of the C89 draft standard). A cast to the smaller container + * type is then required to avoid the compiler warning */ suffix = (unsigned char)(suffix_mask(fields[j].prefix_length) & (unsigned char)i); if (suffix == suffix_mask(fields[j].prefix_length)) { diff --git a/tools/codegen/core/gen_legal_metadata_characters.c b/tools/codegen/core/gen_legal_metadata_characters.c index 3718916577..677fa5c155 100644 --- a/tools/codegen/core/gen_legal_metadata_characters.c +++ b/tools/codegen/core/gen_legal_metadata_characters.c @@ -43,9 +43,8 @@ static void legal(int x) { int bit = x % 8; /* NB: the following integer arithmetic operation needs to be in its * expanded form due to the "integral promotion" performed (see section - * 3.2.1.1 of the C89 draft standard), which in this case upcasts the result - * of the bitwise OR to "unsigned". A cast to the smaller container type is - * then required to avoid the compiler warning */ + * 3.2.1.1 of the C89 draft standard). A cast to the smaller container type + * is then required to avoid the compiler warning */ legal_bits[byte] = (unsigned char)((legal_bits[byte] | (unsigned char)(1 << bit))); } |