vt: hide pedantic warnings around the VT state machine's switch cases

The switch statements use the GCC extension "case X ... Y", and here
it doesn't really make any sense to convert it to "case X: case Y:",
so hide the warnings instead.
This commit is contained in:
Daniel Eklöf 2020-08-23 09:38:37 +02:00
parent aa3985a298
commit 9db78c3122
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

9
vt.c
View file

@ -734,6 +734,11 @@ action_utf8_44(struct terminal *term, uint8_t c)
action_utf8_print(term, term->vt.utf8);
}
#if defined(__GNUC__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wpedantic"
#endif
static enum state
state_ground_switch(struct terminal *term, uint8_t data)
{
@ -1256,6 +1261,10 @@ state_utf8_43_switch(struct terminal *term, uint8_t data)
}
}
#if defined(__GNUC__)
#pragma GCC diagnostic pop
#endif
void
vt_from_slave(struct terminal *term, const uint8_t *data, size_t len)
{