Author xtreak
Recipients eric.smith, serhiy.storchaka, vstinner, xtreak
Date 2018-12-22.14:42:21
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Looking into the code min_width is returned as -2 and hence the assert fails. spec->n_min_width is passed as min_width to _PyUnicode_InsertThousandsGrouping that is used in the assert statement and I came across below comment that min_width can go negative and it's okay. So is the assert statement validating for it to be always greater than or equal to zero not needed?

    /* min_width can go negative, that's okay. format->width == -1 means
       we don't care. */
    if (format->fill_char == '0' && format->align == '=')
        spec->n_min_width = format->width - n_non_digit_non_padding;
        spec->n_min_width = 0;
Date User Action Args
2018-12-22 14:42:23xtreaksetrecipients: + xtreak, vstinner, eric.smith, serhiy.storchaka
2018-12-22 14:42:21xtreaksetmessageid: <>
2018-12-22 14:42:21xtreaklinkissue35560 messages
2018-12-22 14:42:21xtreakcreate