Since lispy is aimed at mainly providing a functional environment it would be very interesting to me if return types could be lazy. Currently I can think of a very simple way that this would work:
Class LazyResult(object):
expression = <non evaluated expression>
def getattr(self, *args, **kwargs):
return expression.getattr(self, *args, **kwargs)
Expressions instead of being evaluated could just be stored in lazy results that were returned (and any operation against them would cause them to be evaluated). This is just a rough idea and I'm sure it would be more complicated.
Since lispy is aimed at mainly providing a functional environment it would be very interesting to me if return types could be lazy. Currently I can think of a very simple way that this would work:
Expressions instead of being evaluated could just be stored in lazy results that were returned (and any operation against them would cause them to be evaluated). This is just a rough idea and I'm sure it would be more complicated.