diff options
| author | Richard Henderson | 2020-06-08 19:41:49 +0200 |
|---|---|---|
| committer | Richard Henderson | 2020-06-09 18:19:48 +0200 |
| commit | fe079aa13d6f77f9d7323b58ab24448e73ae6a93 (patch) | |
| tree | f4df7ae82047199cc5789ec65b5f8324688379de /scripts | |
| parent | tests/decode: Test non-overlapping groups (diff) | |
| download | qemu-fe079aa13d6f77f9d7323b58ab24448e73ae6a93.tar.gz qemu-fe079aa13d6f77f9d7323b58ab24448e73ae6a93.tar.xz qemu-fe079aa13d6f77f9d7323b58ab24448e73ae6a93.zip | |
decodetree: Drop check for less than 2 patterns in a group
While it makes little sense for the end product to have a group
containing only a single pattern, avoiding this case within an
incremental patch set is troublesome.
Because this is expected to be a transient condition, do not
bother "optimizing" this case, e.g. by folding away the group.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/decodetree.py | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/scripts/decodetree.py b/scripts/decodetree.py index 7e3b1d1399..530d41ca62 100755 --- a/scripts/decodetree.py +++ b/scripts/decodetree.py @@ -1024,8 +1024,6 @@ def parse_file(f, parent_pat): if name == '}' or name == ']': if len(toks) != 0: error(start_lineno, 'extra tokens after close brace') - if len(parent_pat.pats) < 2: - error(lineno, 'less than two patterns within braces') # Make sure { } and [ ] nest properly. if (name == '}') != isinstance(parent_pat, IncMultiPattern): |
