Skip to content

Commit

Permalink
fix plural language in singular scenarios
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanfleury committed Feb 3, 2024
1 parent cbe842c commit 647558b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/df/gfx/df_gfx.c
Original file line number Diff line number Diff line change
Expand Up @@ -6793,12 +6793,13 @@ df_single_line_eval_value_strings_from_eval(Arena *arena, DF_EvalVizStringFlags
if(opt_member != 0)
{
U64 member_byte_size = tg_byte_size_from_graph_raddbg_key(graph, rdbg, opt_member->type_key);
str8_list_pushf(arena, &list, "member (%I64u offset, %I64u bytes)", opt_member->off, member_byte_size);
str8_list_pushf(arena, &list, "member (%I64u offset, %I64u byte%s)", opt_member->off, member_byte_size, member_byte_size > 1 ? "s" : "");
}
else
{
String8 basic_type_kind_string = tg_kind_basic_string_table[tg_kind_from_key(eval.type_key)];
str8_list_pushf(arena, &list, "%S (%I64u bytes)", basic_type_kind_string, tg_byte_size_from_graph_raddbg_key(graph, rdbg, eval.type_key));
U64 byte_size = tg_byte_size_from_graph_raddbg_key(graph, rdbg, eval.type_key);
str8_list_pushf(arena, &list, "%S (%I64u byte%s)", basic_type_kind_string, byte_size, byte_size > 1 ? "s" : "");
}
}

Expand Down

0 comments on commit 647558b

Please sign in to comment.