target/sh4: Update DisasContextBase.insn_start
[qemu/kevin.git] / tests / qapi-schema / doc-good.json
blobde38a386e8f6c853d0c6f6bac50418ddeefc3a60
1 # -*- Mode: Python -*-
2 # vim: filetype=python
4 # Positive QAPI doc comment tests
6 { 'pragma': {
7     'doc-required': true,
8     'documentation-exceptions': [ 'Enum', 'Variant1', 'Alternate', 'cmd' ] } }
11 # = Section
15 # == Subsection
17 # *with emphasis*
18 # @var {in braces}
20 # * List item one
21 # * Two, multiple
22 #   lines
24 # * Three
25 #   Still in list
27 # Not in list
29 # - Second list
30 #   Note: still in list
32 # Note: not in list
34 # 1. Third list
35 #    is numbered
37 # 2. another item
39 # Returns: the King
40 # Since: the first age
41 # Notes:
43 # 1. Lorem ipsum dolor sit amet
45 # 2. Ut enim ad minim veniam
47 # Duis aute irure dolor
49 # Example:
51 # -> in
52 # <- out
53 # Examples:
54 # - *verbatim*
55 # - {braces}
59 # @Enum:
61 # @one: The _one_ {and only}, description on the same line
63 # Features:
64 # @enum-feat: Also _one_ {and only}
65 # @enum-member-feat: a member feature
67 # @two is undocumented
69 { 'enum': 'Enum',
70   'data': [ { 'name': 'one', 'if': 'IFONE',
71               'features': [ 'enum-member-feat' ] },
72             'two' ],
73   'features': [ 'enum-feat' ],
74   'if': 'IFCOND' }
77 # @Base:
79 # @base1:
80 #  description starts on a new line,
81 #  minimally indented
83 { 'struct': 'Base', 'data': { 'base1': 'Enum' },
84   'if': { 'all': ['IFALL1', 'IFALL2'] } }
87 # @Variant1:
89 # A paragraph
91 # Another paragraph
93 # @var1 is undocumented
95 # Features:
96 # @variant1-feat: a feature
97 # @member-feat: a member feature
99 { 'struct': 'Variant1',
100   'features': [ 'variant1-feat' ],
101   'data': { 'var1': { 'type': 'str',
102                       'features': [ 'member-feat' ],
103                       'if': 'IFSTR' } } }
106 # @Variant2:
109 { 'struct': 'Variant2', 'data': {} }
112 # @Object:
114 # Features:
115 # @union-feat1: a feature
117 { 'union': 'Object',
118   'features': [ 'union-feat1' ],
119   'base': 'Base',
120   'discriminator': 'base1',
121   'data': { 'one': 'Variant1',
122             'two': { 'type': 'Variant2',
123                      'if': { 'any': ['IFONE', 'IFTWO'] } } } }
126 # @Alternate:
128 # @i: description starts on the same line
129 #     remainder indented the same
130 #     @b is undocumented
132 # Features:
133 # @alt-feat: a feature
135 { 'alternate': 'Alternate',
136   'features': [ 'alt-feat' ],
137   'data': { 'i': 'int', 'b': 'bool' },
138   'if': { 'not': { 'any': [ 'IFONE', 'IFTWO' ] } } }
141 # == Another subsection
145 # @cmd:
147 # @arg1:
148 #     description starts on a new line,
149 #     indented
151 # @arg2: description starts on the same line
152 #     remainder indented differently
154 # Features:
155 # @cmd-feat1: a feature
156 # @cmd-feat2: another feature
158 # Note: @arg3 is undocumented
160 # Returns: @Object
162 # Errors: some
164 # TODO: frobnicate
166 # Notes:
168 #  - Lorem ipsum dolor sit amet
169 #  - Ut enim ad minim veniam
171 #  Duis aute irure dolor
173 # Example:
175 #  -> in
176 #  <- out
178 # Examples:
179 #  - *verbatim*
180 #  - {braces}
182 # Since: 2.10
184 { 'command': 'cmd',
185   'data': { 'arg1': 'int', '*arg2': 'str', 'arg3': 'bool' },
186   'returns': 'Object',
187   'features': [ 'cmd-feat1', 'cmd-feat2' ] }
190 # @cmd-boxed:
191 # If you're bored enough to read this, go see a video of boxed cats
193 # Features:
194 # @cmd-feat1: a feature
195 # @cmd-feat2: another feature
197 # Example:
199 #  -> in
201 #  <- out
203 { 'command': 'cmd-boxed', 'boxed': true,
204   'data': 'Object',
205   'features': [ 'cmd-feat1', 'cmd-feat2' ] }
208 # @EVT_BOXED:
210 # Features:
211 # @feat3: a feature
213 { 'event': 'EVT_BOXED',  'boxed': true,
214   'features': [ 'feat3' ],
215   'data': 'Object' }