checkpoint_total_format is now const

* src/checkpoint.c (checkpoint_total_format):
Now const, and local to format_checkpoint_string.
This commit is contained in:
Paul Eggert
2024-10-31 19:53:25 -07:00
parent f9ed22de9b
commit 0b60228081

View File

@@ -168,12 +168,6 @@ checkpoint_finish_compile (void)
} }
} }
static const char *checkpoint_total_format[] = {
"R",
"W",
"D"
};
static intmax_t static intmax_t
getwidth (FILE *fp) getwidth (FILE *fp)
{ {
@@ -289,7 +283,9 @@ format_checkpoint_string (FILE *fp, idx_t len,
case 'T': case 'T':
{ {
const char **fmt = checkpoint_total_format, *fmtbuf[3]; static char const *const checkpoint_total_format[]
= { "R", "W", "D" };
char const *const *fmt = checkpoint_total_format, *fmtbuf[3];
struct wordsplit ws; struct wordsplit ws;
compute_duration_ns (); compute_duration_ns ();