reportlab/platypus/doctemplate.py
changeset 2956 5c17941635bd
parent 2955 cc16265295fb
child 2957 137b1d6cdca4
--- a/reportlab/platypus/doctemplate.py	Thu Aug 21 16:50:11 2008 +0000
+++ b/reportlab/platypus/doctemplate.py	Fri Aug 22 10:31:32 2008 +0000
@@ -893,6 +893,7 @@
     _allowedLifetimes = 'page','frame','build','forever'
     def docAssign(self,var,expr,lifetime):
         var=var.strip()+'\n'
+        if not isinstance(expr,(str,unicode)): expr=str(expr)
         expr=expr.strip()
         T=tokenize.generate_tokens(lambda :var)
         tokens=[]