[IPython-dev] [Ipython-svndiff] 2885 - Do not replace # w/ \# anymore

Ville M. Vainio vivainio at gmail.com
Tue Dec 11 10:04:52 EST 2007


On Dec 11, 2007 8:55 AM, Fernando Perez <fperez.net at gmail.com> wrote:

> Mmh, when replacing code like this, which was obviously put in there
> explicitly and for some reason, please double check with others first.

I asked about this a while ago, but you couldn't figure out back then
why it was there. I figured that this early in the svn cycle, we could
smoke out the real reason. And that appears to be the case :-).

> In this case, the behavior that was in there was to ensure
> compatibility with the shell:
>
> In [1]: !echo hi # cmd
> hi # cmd
>
> Which is how the shell behaves:
>
> maqroll[~]> echo hi # cmd
> hi # cmd
>
> Now, after the above commit:
>
> In [1]: !echo hi # cmd
> hi
>
> I won't revert (yet) the commit  because I imagine there was a reason
> for it, but the right approach is to find a solution for both needs,
> not to blindly break what was in there.

Now that we know the root of the problem, we can make escaping # a
linux-specific thing. On win32, escaping # broke all the command lines
that have #.

-- 
Ville M. Vainio - vivainio.googlepages.com
blog=360.yahoo.com/villevainio - g[mail | talk]='vivainio'



More information about the IPython-dev mailing list