[Python-Dev] PEP 215 redux: toward a simplified consensus?

Greg Ward gward@python.net
Wed, 27 Feb 2002 08:56:16 -0500

[Greg Ewing]
> I suggest '^', since it does a nice job of suggesting
> "inject stuff into this string". We can have both a
> prefix form for compile-time interpolation:
>   a = ^ "My name is $name"
> and an infix form for run-time interpolation:
>   a = "My name is $name" ^ dict

> I think I suggested using ~ for this at IPC10:
>     a = ~'my name is $name'
> for the compile-time interpolation.  I don't think it matters much
> which operator is chosen (let Guido decide).

-1 on all line-noise string modifiers.  (I just looked at Barry's
example and part of my reptilian hindbrain thought it was a regex match.
Don't do that to Perl and awk refugees, please!)

All existing string modifiers are letters; how about "i" for

   a = i"my name is $name"

Assuming of course that we really do need yet another flavour of

Greg Ward - programmer-at-large                         gward@python.net
Time flies like an arrow; fruit flies like a banana.