From ef801a9bb1e2cf276a8482c4ad1910f72de223f8 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Wed, 15 Mar 2017 13:57:08 +0100 Subject: qapi: Prefer single-quoted strings more consistently PEP 8 advises: In Python, single-quoted strings and double-quoted strings are the same. This PEP does not make a recommendation for this. Pick a rule and stick to it. When a string contains single or double quote characters, however, use the other one to avoid backslashes in the string. It improves readability. The QAPI generators succeed at picking a rule, but fail at sticking to it. Convert a bunch of double-quoted strings to single-quoted ones. Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake Message-Id: <1489582656-31133-20-git-send-email-armbru@redhat.com> --- scripts/qapi-event.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts/qapi-event.py') diff --git a/scripts/qapi-event.py b/scripts/qapi-event.py index f4eb7f8..0485e39 100644 --- a/scripts/qapi-event.py +++ b/scripts/qapi-event.py @@ -223,7 +223,7 @@ fdecl.write(mcgen(''' ''', prefix=prefix)) -event_enum_name = c_name(prefix + "QAPIEvent", protect=False) +event_enum_name = c_name(prefix + 'QAPIEvent', protect=False) schema = QAPISchema(input_file) gen = QAPISchemaGenEventVisitor() -- cgit v1.1