28.11.17 15:36, Nick Coghlan пише:
- I'm opposed to making assert substantially different from the way it works now
If sometimes we will change assert I would prefer to make it more similar to assert in pytest. Output values of the final and intermediate expressions. The hardest problem -- the repr can be very long and expensive, we need an alternate protocol for producing a shortened representation.
- I'm in favour of adding a new "ensure()" builtin that encapsulates
the check-and-raise logic
Then may be add a new "die()" buildin? ;-)
0 <= r < abs(y) or die()