Updates:
        Status: Valid

Comment #7 on issue 3062 by [email protected]: set and frozenset are not printed correctly with latex()
http://code.google.com/p/sympy/issues/detail?id=3062

I get

In [128]: latex(set([x**2]))
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
/Users/aaronmeurer/Documents/Python/sympy/sympy/<ipython-input-128-6e868d920314> in <module>()
----> 1 latex(set([x**2]))

/Users/aaronmeurer/Documents/Python/sympy/sympy/sympy/printing/latex.py in latex(expr, **settings)
   1222     """
   1223
-> 1224     return LatexPrinter(settings).doprint(expr)
   1225
   1226 def print_latex(expr, **settings):

/Users/aaronmeurer/Documents/Python/sympy/sympy/sympy/printing/latex.py in doprint(self, expr)
     75
     76     def doprint(self, expr):
---> 77         tex = Printer.doprint(self, expr)
     78
     79         if self._settings['mode'] == 'plain':

/Users/aaronmeurer/Documents/Python/sympy/sympy/sympy/printing/printer.py in doprint(self, expr)
    228     def doprint(self, expr):
229 """Returns printer's representation for expr (as a string)"""
--> 230         return self._str(self._print(expr))
    231
    232     def _print(self, expr, *args):

/Users/aaronmeurer/Documents/Python/sympy/sympy/sympy/printing/printer.py in _print(self, expr, *args)
    252                 printmethod = '_print_' + cls.__name__
    253                 if hasattr(self, printmethod):
--> 254                     return getattr(self, printmethod)(expr, *args)
    255
    256             # Unknown object, fall back to the emptyPrinter.

/Users/aaronmeurer/Documents/Python/sympy/sympy/sympy/printing/latex.py in _print_FiniteSet(self, s)
    991             printset = s.args[:3] + ('...',) + s.args[-3:]
    992         else:
--> 993             printset = s.args
    994         return (r"\left\{"
    995               + r", ".join(self._print(el) for el in printset)

AttributeError: 'set' object has no attribute 'args'

and the same for frozenset.

--
You received this message because you are subscribed to the Google Groups 
"sympy-issues" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sympy-issues?hl=en.

Reply via email to