All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v4 0/3] qapi: Allow modularization of QAPI schema files
@ 2014-02-28 15:53 Lluís Vilanova
  2014-02-28 15:53 ` [Qemu-devel] [PATCH v4 1/3] qapi: Use an explicit input file Lluís Vilanova
                   ` (3 more replies)
  0 siblings, 4 replies; 24+ messages in thread
From: Lluís Vilanova @ 2014-02-28 15:53 UTC (permalink / raw)
  To: qemu-devel

Adds the "include(...)" primitive to the syntax of QAPI schema files, allowing
these to be modularized into multiple per-topic files in the future.

Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
---

Changes in v4:

* Rebase on 3e890c7.
* Minor cosmetic changes.
* Fix recording of included files in case of a cycle error.
* Add a more complex include cycle test.


Changes in v3:

* Fix documentation examples regarding how the input file is passed to the
  scripts.
* Add documentation for the 'include' directive.
* Detect inclusion loops.
* Fix "tests/qapi-schema/test-qapi.py" and "tests/Makefile" to use an explicit
  input file when running tests.
* Fix QAPI tests to cope with an explicit input file.
* Add tests for the "include" directive.


Changes in v2:

* Change the scripts to use an explicit input file instead of standard input.
* Fix "tests/Makefile" to use the new argument.
* Get the input directory for the "include" directive from the input file
  dirname.


Lluís Vilanova (3):
      qapi: Use an explicit input file
      qapi: Add a primitive to include other files from a QAPI schema file
      qapi: Add tests for the "include" directive


 Makefile                                      |   24 ++++++++++---
 docs/qapi-code-gen.txt                        |   12 +++++-
 scripts/qapi-commands.py                      |   10 ++++-
 scripts/qapi-types.py                         |    9 +++--
 scripts/qapi-visit.py                         |    9 +++--
 scripts/qapi.py                               |   47 +++++++++++++++++++++++--
 tests/Makefile                                |   18 +++++++---
 tests/qapi-schema/funny-char.err              |    2 +
 tests/qapi-schema/include-cycle-b.json        |    1 +
 tests/qapi-schema/include-cycle-c.json        |    1 +
 tests/qapi-schema/include-cycle.err           |    1 +
 tests/qapi-schema/include-cycle.exit          |    1 +
 tests/qapi-schema/include-cycle.json          |    1 +
 tests/qapi-schema/include-cycle.out           |    0 
 tests/qapi-schema/include-nested-err.err      |    1 +
 tests/qapi-schema/include-nested-err.exit     |    1 +
 tests/qapi-schema/include-nested-err.json     |    1 +
 tests/qapi-schema/include-nested-err.out      |    0 
 tests/qapi-schema/include-no-file.err         |    1 +
 tests/qapi-schema/include-no-file.exit        |    1 +
 tests/qapi-schema/include-no-file.json        |    1 +
 tests/qapi-schema/include-no-file.out         |    0 
 tests/qapi-schema/include-self-cycle.err      |    1 +
 tests/qapi-schema/include-self-cycle.exit     |    1 +
 tests/qapi-schema/include-self-cycle.json     |    1 +
 tests/qapi-schema/include-self-cycle.out      |    0 
 tests/qapi-schema/include-simple-sub.json     |    2 +
 tests/qapi-schema/include-simple.err          |    0 
 tests/qapi-schema/include-simple.exit         |    1 +
 tests/qapi-schema/include-simple.json         |    1 +
 tests/qapi-schema/include-simple.out          |    3 ++
 tests/qapi-schema/missing-colon.err           |    2 +
 tests/qapi-schema/missing-comma-list.err      |    2 +
 tests/qapi-schema/missing-comma-object.err    |    2 +
 tests/qapi-schema/non-objects.err             |    2 +
 tests/qapi-schema/quoted-structural-chars.err |    2 +
 tests/qapi-schema/test-qapi.py                |    3 +-
 tests/qapi-schema/trailing-comma-list.err     |    2 +
 tests/qapi-schema/trailing-comma-object.err   |    2 +
 tests/qapi-schema/unclosed-list.err           |    2 +
 tests/qapi-schema/unclosed-object.err         |    2 +
 tests/qapi-schema/unclosed-string.err         |    2 +
 42 files changed, 137 insertions(+), 38 deletions(-)
 create mode 100644 tests/qapi-schema/include-cycle-b.json
 create mode 100644 tests/qapi-schema/include-cycle-c.json
 create mode 100644 tests/qapi-schema/include-cycle.err
 create mode 100644 tests/qapi-schema/include-cycle.exit
 create mode 100644 tests/qapi-schema/include-cycle.json
 create mode 100644 tests/qapi-schema/include-cycle.out
 create mode 100644 tests/qapi-schema/include-nested-err.err
 create mode 100644 tests/qapi-schema/include-nested-err.exit
 create mode 100644 tests/qapi-schema/include-nested-err.json
 create mode 100644 tests/qapi-schema/include-nested-err.out
 create mode 100644 tests/qapi-schema/include-no-file.err
 create mode 100644 tests/qapi-schema/include-no-file.exit
 create mode 100644 tests/qapi-schema/include-no-file.json
 create mode 100644 tests/qapi-schema/include-no-file.out
 create mode 100644 tests/qapi-schema/include-self-cycle.err
 create mode 100644 tests/qapi-schema/include-self-cycle.exit
 create mode 100644 tests/qapi-schema/include-self-cycle.json
 create mode 100644 tests/qapi-schema/include-self-cycle.out
 create mode 100644 tests/qapi-schema/include-simple-sub.json
 create mode 100644 tests/qapi-schema/include-simple.err
 create mode 100644 tests/qapi-schema/include-simple.exit
 create mode 100644 tests/qapi-schema/include-simple.json
 create mode 100644 tests/qapi-schema/include-simple.out


To: qemu-devel@nongnu.org
Cc: Luiz Capitulino <lcapitulino@redhat.com>
Cc: Markus Armbruster <armbru@redhat.com>
Cc: Eric Blake <eblake@redhat.com>

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

end of thread, other threads:[~2014-03-17 14:20 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-28 15:53 [Qemu-devel] [PATCH v4 0/3] qapi: Allow modularization of QAPI schema files Lluís Vilanova
2014-02-28 15:53 ` [Qemu-devel] [PATCH v4 1/3] qapi: Use an explicit input file Lluís Vilanova
2014-03-01  8:35   ` Markus Armbruster
2014-03-03 14:25     ` Lluís Vilanova
2014-03-03 15:42       ` Markus Armbruster
2014-03-03 16:59         ` Lluís Vilanova
2014-03-04 13:17           ` Markus Armbruster
2014-03-05  0:58             ` Lluís Vilanova
2014-02-28 15:53 ` [Qemu-devel] [PATCH v4 2/3] qapi: Add a primitive to include other files from a QAPI schema file Lluís Vilanova
2014-03-01  8:57   ` Markus Armbruster
2014-03-03 14:21     ` Lluís Vilanova
2014-03-03 15:27       ` Markus Armbruster
2014-03-03 17:04         ` Lluís Vilanova
2014-03-03 17:56         ` Eric Blake
2014-03-04  8:02           ` Markus Armbruster
2014-03-13 15:33             ` Benoît Canet
2014-03-13 15:54               ` Eric Blake
2014-03-13 18:05                 ` Lluís Vilanova
2014-03-14 16:35                   ` Benoît Canet
2014-03-14 20:24                     ` Lluís Vilanova
2014-03-14 21:55                       ` Benoît Canet
2014-03-17 14:20                 ` Benoît Canet
2014-02-28 15:53 ` [Qemu-devel] [PATCH v4 3/3] qapi: Add tests for the "include" directive Lluís Vilanova
2014-02-28 16:18 ` [Qemu-devel] [PATCH v4 0/3] qapi: Allow modularization of QAPI schema files Eric Blake

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.