[Python-ideas] PEP 505: None-aware operators: operators ?= and ?? and OR

Grégory Lielens gregory.lielens at gmail.com
Fri Jul 20 09:44:16 EDT 2018


I like it much better than the operator version, if I understand correctly, it's like a watcher for special value, that monitor the stack.
Danger is that it monitor the whole stack, so that final result is dependent on how much you decompose your algorithm into nested fiction calls: all return values will be monitored, and only return values...
But if you refactor a big function into nested functions, and happen to return the special value in the new subfunctions, it will have side effects, that can not be known within the context: it expose internals that used to be hidden, deliberately so...


More information about the Python-ideas mailing list