All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/3] qapi: Simplify enum generation
@ 2023-03-15 11:28 Philippe Mathieu-Daudé
  2023-03-15 11:28 ` [PATCH v3 1/3] scripts/git.orderfile: Display QAPI script changes before schema ones Philippe Mathieu-Daudé
                   ` (2 more replies)
  0 siblings, 3 replies; 19+ messages in thread
From: Philippe Mathieu-Daudé @ 2023-03-15 11:28 UTC (permalink / raw)
  To: qemu-devel
  Cc: Markus Armbruster, Pavel Dovgalyuk, Dr. David Alan Gilbert,
	Michael Roth, Stefan Berger, Paolo Bonzini,
	Marc-André Lureau, Juan Quintela, Gerd Hoffmann,
	Philippe Mathieu-Daudé

QAPI generating enum count as part of the enum forces handling
impossible switch cases. Modify qapi/types.py to generate the
enum count as a definition.
Do not try to cover the unreachable 'default' case.
Clean files covering unreachable foo__MAX case.

Since v2:
- Post correct branch generating empty foo-qapi-emit-events.h

Since v1:
- Update documentation (Markus)
- Do not generate empty enums (Markus)
- Collect R-b tags

Philippe Mathieu-Daudé (3):
  scripts/git.orderfile: Display QAPI script changes before schema ones
  qapi: Do not generate empty enum
  qapi: Generate enum count as definition

 docs/devel/qapi-code-gen.rst | 10 +++++-----
 scripts/qapi/events.py       |  2 ++
 scripts/qapi/schema.py       |  5 ++++-
 scripts/qapi/types.py        | 13 +++++++++----
 scripts/qapi/visit.py        |  2 --
 audio/audio_template.h       |  3 ---
 audio/audio.c                |  6 ------
 migration/migration.c        |  2 --
 replay/replay-input.c        | 12 ------------
 softmmu/tpm-hmp-cmds.c       |  2 --
 ui/input-linux.c             |  4 ----
 ui/input.c                   |  6 ------
 scripts/git.orderfile        |  2 ++
 13 files changed, 22 insertions(+), 47 deletions(-)

-- 
2.38.1



^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2023-03-22  5:47 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-15 11:28 [PATCH v3 0/3] qapi: Simplify enum generation Philippe Mathieu-Daudé
2023-03-15 11:28 ` [PATCH v3 1/3] scripts/git.orderfile: Display QAPI script changes before schema ones Philippe Mathieu-Daudé
2023-03-15 15:14   ` Philippe Mathieu-Daudé
2023-03-15 20:30   ` Juan Quintela
2023-03-15 11:28 ` [PATCH v3 2/3] qapi: Do not generate empty enum Philippe Mathieu-Daudé
2023-03-15 15:02   ` Richard Henderson
2023-03-16 12:31   ` Markus Armbruster
2023-03-16 13:54     ` Daniel P. Berrangé
2023-03-16 14:39       ` Juan Quintela
2023-03-16 14:42         ` Daniel P. Berrangé
2023-03-16 14:57       ` Markus Armbruster
2023-03-21 14:31         ` Philippe Mathieu-Daudé
2023-03-21 15:19           ` Daniel P. Berrangé
2023-03-21 21:43             ` Eric Blake
2023-03-22  5:45               ` Markus Armbruster
2023-03-21 14:48         ` Philippe Mathieu-Daudé
2023-03-21 19:00           ` Markus Armbruster
2023-03-15 11:28 ` [PATCH v3 3/3] qapi: Generate enum count as definition Philippe Mathieu-Daudé
2023-03-15 19:58   ` Dr. David Alan Gilbert

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.