• Tim Peters's avatar
    Replaced the FileStorage _packt member with a _pack_is_in_progress bool. · b21efa8d
    Tim Peters authored
    The only values _packt ever had were z64 and None.  The only thing _packt
    was used for that appeared to make sense was to block undo while a pack
    was in progress, and a bool works better for that.  tids were compared
    to _packt in a few spots, but since the only values _packt could have
    were in {z64, None}, the comparisons were doomed to (regardless of tid)
    return "greater than" (z64) or to be undefined (None; although in recent
    Pythons None is reliably less than objects of other types, so "greater
    than" was the only outcome possible from these comparisons under 2.3.3).
    Removed these comparisons, collapsing surrounding expressions to
    equivalents taking into account that tid < self._packt was always false.
    b21efa8d
FileStorage.py 68.3 KB