Fixed clang-format.

pull/13171/head
Joshua Haberman 3 years ago
parent 2e141b24fc
commit 9715597895
  1. 3
      upb/def.c
  2. 3
      upbc/protoc-gen-upb.cc

@ -1624,7 +1624,8 @@ static void make_layout(symtab_addctx* ctx, const upb_MessageDef* m) {
/* Sort fields by number. */ /* Sort fields by number. */
if (fields) { if (fields) {
qsort(fields, upb_MessageDef_numfields(m), sizeof(*fields), field_number_cmp); qsort(fields, upb_MessageDef_numfields(m), sizeof(*fields),
field_number_cmp);
} }
assign_layout_indices(m, l, fields); assign_layout_indices(m, l, fields);
} }

@ -1323,8 +1323,7 @@ int WriteEnums(const protobuf::FileDescriptor* file, Output& output) {
if (!values.empty()) { if (!values.empty()) {
values_init = EnumInit(e) + "_values"; values_init = EnumInit(e) + "_values";
output("static const int32_t $0[$1] = {\n", values_init, output("static const int32_t $0[$1] = {\n", values_init, values.size());
values.size());
for (auto value : values) { for (auto value : values) {
output(" $0,\n", value); output(" $0,\n", value);
} }

Loading…
Cancel
Save