[IPython-dev] pasting lines with "\" into ipython

Ondrej Certik ondrej@certik...
Fri May 22 11:00:48 CDT 2009


On Fri, May 22, 2009 at 7:36 AM, Gökhan SEVER <gokhansever@gmail.com> wrote:
> Hi Ondrej,
>
> I don't know the exact answer, however if you put the comma after back-slash
> on a new line it works.
>
> In [10]: from hermes2d import Mesh, H1Shapeset, PrecalcShapeset, H1Space \
>    ....: ,WeakForm, Solution, ScalarView, LinSystem, DummySolver
>
> and IPython complains about a missing module as expected other than a syntax
> error :)

Indeed, that works for me:

In [1]: from hermes2d import Mesh, H1Shapeset, PrecalcShapeset, H1Space \
   ...: ,WeakForm, Solution, ScalarView, LinSystem, DummySolver

In [2]:

Thanks for the tip. I think the last comma could be allowed in
ipython, I think it's very natural to have it there.

Ondrej


More information about the IPython-dev mailing list