| 49 | sizes.extend([10, 100, 1000]) |
| 50 | |
| 51 | class Complains(object): |
| 52 | maybe_complain = True |
| 53 | |
| 54 | def __init__(self, i): |
| 55 | self.i = i |
| 56 | |
| 57 | def __lt__(self, other): |
| 58 | if Complains.maybe_complain and random.random() < 0.001: |
| 59 | if verbose: |
| 60 | print(" complaining at", self, other) |
| 61 | raise RuntimeError |
| 62 | return self.i < other.i |
| 63 | |
| 64 | def __repr__(self): |
| 65 | return "Complains(%d)" % self.i |
| 66 | |
| 67 | class Stable(object): |
| 68 | def __init__(self, key, i): |
no outgoing calls
searching dependent graphs…