From ed5e29cba500c2336aacdb7c77953f1064235b72 Mon Sep 17 00:00:00 2001 From: Emmanuel Arias Date: Thu, 21 Mar 2019 01:39:17 -0300 Subject: bpo-36385: Add ``elif`` sentence on to avoid multiple ``if`` (GH-12478) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Currently, when arguments on Parser/asdl_c.py are parsed ``ìf`` sentence is used. This PR Propose to use ``elif`` to avoid multiple evaluting of the ifs. https://bugs.python.org/issue36385 --- Parser/asdl_c.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Parser/asdl_c.py b/Parser/asdl_c.py index 5224755..4091b6d 100644 --- a/Parser/asdl_c.py +++ b/Parser/asdl_c.py @@ -1313,9 +1313,9 @@ if __name__ == "__main__": for o, v in opts: if o == '-h': H_FILE = v - if o == '-c': + elif o == '-c': C_FILE = v - if o == '-d': + elif o == '-d': dump_module = True if H_FILE and C_FILE: print('Must specify exactly one output file') -- cgit v0.12