Added aggressive caching for common typeclassed variables.

This commit is contained in:
Griatch 2012-02-25 23:37:50 +01:00
parent b99db98191
commit 1fa5791e19
3 changed files with 56 additions and 69 deletions

View file

@ -26,8 +26,7 @@ def is_iter(iterable):
def make_iter(obj):
"Makes sure that the object is always iterable."
if not hasattr(iterable, '__iter__'):
return [obj]
if not hasattr(obj, '__iter__'): return [obj]
return obj
def fill(text, width=78, indent=0):