Re: Lazy evaluated

2013-03-29 Thread Habibutsu
sinstance(value, int): 10|print value,"- is int" 11|else: 12|print value,"- is not int" Task is to create lazy evaluation for function 'foo'. For decision this task we create special function 'lazy' which turn original function into a la

Re: Lazy evaluated

2013-03-28 Thread Steven D'Aprano
isinstance(value, int): > 10|print value,"- is int" > 11|else: > 12|print value,"- is not int" > > Task is to create lazy evaluation for function 'foo'. For decision this > task we create special function 'lazy' which turn

Lazy evaluated

2013-03-28 Thread Habibutsu
- is not int" Task is to create lazy evaluation for function 'foo'. For decision this task we create special function 'lazy' which turn original function into a lazy evaluated function by means of creating proxy object that evaluated value if needed. We add following c