[Python-ideas] Delayed Execution via Keyword

Pavol Lisy pavol.lisy at gmail.com
Sun Feb 19 17:54:38 EST 2017

On 2/19/17, Michel Desmoulin <desmoulinmichel at gmail.com> wrote:

> Evnetually we also may need to allow this:
> a = lazy stuff
> if a is not lazy:
>     print(a)
> But then lazy can't be used a var name to help with the transition.

What about this?

if not inspect.islazy(a):

Next idea is probably obvious:

class Busy_Beaver:
    ''' we want to be sure that beaver is disturbed only if it is
really necessary '''
    def __call_me_later__(self, n):
        return too_expensive(n)

More information about the Python-ideas mailing list