Author paul.j3
Recipients bethard, chris.jerdonek, gfxmonk, martin.panter, paul.j3, tshepang, waltermundt
Date 2013-08-28.23:14:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1377731640.23.0.845238561528.issue15112@psf.upfronthosting.co.za>
In-reply-to
Content
These three changes end up testing for the same thing. The initial 'if' catches different test cases.  'subparsers' or 'remainder' might 'confuse' the 'O' test.  The zero-width test ends up weeding out everything but the test cases added for this issue.

    # if we haven't hit the end of the command line strings,
    if start_index + sum(arg_counts) != len(arg_strings_pattern):
        while arg_counts and arg_counts[-1] == 0: 
            arg_counts.pop()

    # same test using selected_pattern (= arg_strings_pattern[start_index:])
    if len(selected_pattern) != sum(arg_counts):
        while arg_counts and arg_counts[-1] == 0: 
            arg_counts.pop()

    # alt test: test for optional in the remaining pattern
    if 'O' in selected_pattern:
        while arg_counts and arg_counts[-1] == 0: 
            arg_counts.pop()
History
Date User Action Args
2013-08-28 23:14:00paul.j3setrecipients: + paul.j3, bethard, gfxmonk, chris.jerdonek, tshepang, martin.panter, waltermundt
2013-08-28 23:14:00paul.j3setmessageid: <1377731640.23.0.845238561528.issue15112@psf.upfronthosting.co.za>
2013-08-28 23:14:00paul.j3linkissue15112 messages
2013-08-28 23:14:00paul.j3create