The IPython terminal has used Python Prompt Toolkit since version 5, so PPT
would be my default choice for any shell or console applications (though I
haven't used it for a few years).
-- Carl Smith
carl.in...@gmail.com
On Sat, 17 Oct 2020 at 20:51, Ethan Furman wrote:
> On 10/17/20
I shouldn't let it bother me, but that "Sent from my iPhone" cruft really
gets under my skin.
-- Carl Smith
carl.in...@gmail.com
On Mon, 4 Feb 2019 at 11:17, Paul Moore wrote:
> On Mon, 4 Feb 2019 at 05:36, Christopher Barker
> wrote:
> >
> > This is getting
Ah. Nice one. I'll look through that.
-- Carl Smith
carl.in...@gmail.com
On 29 May 2018 at 19:52, Chris Angelico wrote:
> On Wed, May 30, 2018 at 4:48 AM, Carl Smith wrote:
> > Nah??
>
> Nah. It's already been discussed at interminable length as part of PEP
> 5
Nah??
-- Carl Smith
carl.in...@gmail.com
On 24 May 2018 at 19:24, Carl Smith wrote:
> This is another suggestion for new syntax for assigning a name to the value
> of the predicate in an if, elif or while statement. It still uses `as` for
> its keyword, but with (more flexible) param
rides. That is very useful information that belongs
there.
Best,
-- Carl Smith
carl.in...@gmail.com
On 26 May 2018 at 01:06, Michael Lohmann
wrote:
> Hi!
>
> ***Disclaimer: I am relatively new to Python***
>
> I propose to add some mechanism that can automatically collect everyt
You cannot have `expression if expression` in a language that also supports
`expression if expression else expression` (like Python). Otherwise, you
have
the dangling else problem:
https://en.wikipedia.org/wiki/Dangling_else
-- Carl Smith
carl.in...@gmail.com
On 25 May 2018 at 15:21, Rob
split() as (command, *args):
if run(command, parse(args)) as (result): render(result)
else: sys.exit()
-- Carl Smith
carl.in...@gmail.com
___
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ide
er of them.
I'm not sure on the feature, but thought `let` was a perfect name for it.
-- Carl Smith
carl.in...@gmail.com
On 23 May 2018 at 19:48, Kirill Balunov wrote:
>
>
> 2018-05-23 17:54 GMT+03:00 Mike Miller :
>
>>
>> On 2018-05-22 14:32, Kirill Balunov w
preciate being told if my contribution isn't
especially
welcome.
Best,
-- Carl Smith
carl.in...@gmail.com
On 22 May 2018 at 02:58, Chris Angelico wrote:
> On Tue, May 22, 2018 at 11:45 AM, Brendan Barnwell
> wrote:
> > On 2018-05-21 12:11, Chris Angelico wrote:
>
ass` grammar.
-- Carl Smith
carl.in...@gmail.com
On 21 May 2018 at 22:37, Carl Smith wrote:
> Chris makes a lot of good points regarding *which* languages to look at,
> but
> it seems like that line of enquiry is unlikely to suggest anything more
> than it
> has so far, especially if we
upport the feature or they're
wacky.
If anything, the survey says we need to think outside the box.
-- Carl Smith
carl.in...@gmail.com
On 21 May 2018 at 20:11, Chris Angelico wrote:
> On Tue, May 22, 2018 at 2:43 AM, Mike Miller
> wrote:
> > To clarify there were three main crit
ove
this with more indicatively named functions in practice.
-- Carl Smith
carl.in...@gmail.com
On 21 May 2018 at 14:14, Rhodri James wrote:
> On 21/05/18 12:29, Daniel Moisset wrote:
>
>> On 21 May 2018 at 12:05, Rhodri James wrote:
>>
>>
>>> Thanks for the
Sorry, hit send by accident. I meant to say:
do_something(v) *if* v != INCONVENIENT_SENTINEL *else break*
-- Carl Smith
carl.in...@gmail.com
On 21 May 2018 at 13:37, Carl Smith wrote:
> v = get_something()
>
> while v != INCONVENIENT_SENTINEL:
>
> do_somethi
ally like to be able to use jump
statements
in ternary expressions, like:
do_something(v)
But that's another story.
-- Carl Smith
carl.in...@gmail.com
On 21 May 2018 at 13:22, Juancarlo Añez wrote:
>
> while ((v = get_something()) != INCONVENIENT_SENTINEL)
>> do_so
> JavaScript and PHP are abysmally designed languages, so we should
> put little weight on any precedent they set.
JavaScript has issues, due to its unique history, but to dismiss
the entire language as too poorly designed to take seriously...
Many clever people prefer JS to Python.
-
I was asked earlier to summarise the the proposal I've been advocating for,
but
have already gone over the central points a few times. I'll try and find
time to
write a clear explanation soon.
-- Carl Smith
carl.in...@gmail.com
On 18 May 2018 at 19:54, Neil Girdhar wrote:
>
>
erfect backwards compatibility. Just saying :)
-- Carl Smith
carl.in...@gmail.com
On 17 May 2018 at 22:38, Rob Cliffe via Python-ideas <
python-ideas@python.org> wrote:
>
>
> On 16/05/2018 10:12, Stephan Houben wrote:
>
>> Hi all,
>>
>> One problem already alluded
e without restrictions, but old code would carry on working with
the old name.
TLDR: The syntax and semantics of old code would remain totally unchanged.
-- Carl Smith
carl.in...@gmail.com
On 17 May 2018 at 01:21, Steven D'Aprano wrote:
> On Thu, May 17, 2018 at 10:58:34AM +1200, Gre
oo. But, if we are going to do it, I
have a strong preference for
a specific approach.
-- Carl Smith
carl.in...@gmail.com
On 16 May 2018 at 20:40, Todd wrote:
> On Wed, May 16, 2018 at 2:17 PM, Carl Smith wrote:
>
>> > Not if you need to make changes in the same tens of thousan
words that are already names.
-- Carl Smith
carl.in...@gmail.com
On 16 May 2018 at 20:03, Carl Smith wrote:
> If `def(if=3)...` works implicitly, then why not make `if = 3`, `x.if =
> 3`, `import if`, `def if` and `class if` implicit too?
>
> Another issue is what happens her
in code that uses it as a keyword.
-- Carl Smith
carl.in...@gmail.com
On 16 May 2018 at 18:24, Adam Bartoš wrote:
> Hello,
>
> I have yet another idea regarding the the clashes between new keywords and
> already used names. How about introducing two new keywords *wink* that
>
> There can be 2 escape characters '\' and '.'
That's clever, but then we have to put a slash in front of names in
imports, assignments and keyword arguments, but not properties.
-- Carl Smith
carl.in...@gmail.com
On 16 May 2018 at 19:17, Carl Smith wrote:
> &g
t sense. Assigning
to `self.until`
or assigning
to `until` inside a subclass should not be a syntax error. A NameError
would be correct.
It worth mentioning that the cost of checking only applies to cases where
the name in question is also
keyword, so almost never.
-- Carl Smith
carl.in...@gma
: cannot create names that are keywords
in the same context`.
Runtime errors still seem preferable to making keywords legally names in
the same file (especially if we have to escape the names).
-- Carl Smith
carl.in...@gmail.com
On 16 May 2018 at 15:26, Carl Smith wrote:
> Thanks for the reply T
.
None of this would actually apply to `True`, as it's a reserved word in all
versions. The proposal only applies to new keywords that are used as names
in other libraries.
Again, thanks for taking the time.
-- Carl Smith
carl.in...@gmail.com
On 16 May 2018 at 14:46, Todd wrote:
> On
> On Tue, May 15, 2018 at 8:41 PM, Steven D'Aprano
> wrote:
>
>> Inspired by Alex Brault's post:
>>
>> https://mail.python.org/pipermail/python-ideas/2018-May/050750.html
>>
>> I'd like to suggest we copy C#'s idea of verbatim identifiers, but using
>> a backslash rather than @ sign:
>>
>> \n
thereafter (and `x foo y` is a SyntaxError)
else...
you get the idea.
-- Carl Smith
carl.in...@gmail.com
On 14 May 2018 at 22:06, Carl Smith wrote:
> Just to be clear, if `foo` was introduced as a new infix operator,
> projects that used `foo`
> as a name would not be able to also use `f
Just to be clear, if `foo` was introduced as a new infix operator, projects
that used `foo`
as a name would not be able to also use `foo` as an infix operator in the
file that defines
`foo` as a name, but could use the operator throughout the rest of their
project.
-- Carl Smith
carl.in
, before the equals sign:
(=)
If Python allowed those three examples (but still prevented users from
*defining* names
that are keywords) new keywords could be introduced without breaking old
code , and the
language would only require relatively minor tweaking.
-- Carl Smith
carl.in...@gmail.com
.
It could be done, but it's not especially relevant here, so I'll shut up
now.
-- Carl Smith
carl.in...@gmail.com
On 14 May 2018 at 03:47, Rob Cliffe via Python-ideas <
python-ideas@python.org> wrote:
>
>
> On 13/05/2018 19:19, Guido van Rossum wrote:
>
> As an
on 4, as a user...
-- Carl Smith
carl.in...@gmail.com
On 14 May 2018 at 02:28, Greg Ewing wrote:
> Rob Cliffe via Python-ideas wrote:
>
>> def and(x, y):
>> return ...
>>
>> # and(1,2) # Oops, SyntaxError. Oh, I know:
>> globals(
function of width and height,
equal to width by height*.
-- Carl Smith
carl.in...@gmail.com
On 12 May 2018 at 18:24, Steven D'Aprano wrote:
> On Sat, May 12, 2018 at 08:16:07AM -0700, Neil Girdhar wrote:
>
> > I love given compared with := mainly because
> >
> > S
Can't we just tell everyone to speak US English, and go back to ASCII? It
would be a less painful migration.
-- Carl Smith
carl.in...@gmail.com
On 23 November 2017 at 14:16, Chris Angelico wrote:
> On Fri, Nov 24, 2017 at 1:10 AM, Mikhail V wrote:
> > Well, then there is some b
Rather than 'update' the Zen of Python, it seems better to create something
original, maybe derived from the Zen, and see if it becomes popular in its
own right. It'd be fun to see extensions and alternatives, but there's no
reason to change a classic work that helped to define the culture.
Sorry
ators as
a Pythonic alternative [I haven't really considered that properly to be
honest], but you can't just tell people not to do something that they see
as elegant and idiomatic.
Best -- Carl Smith
-- Carl Smith
carl.in...@gmail.com
On 12 August 2017 at 17:22, Nick Coghlan wrote:
>
es that library authors use, like
operator overloading, ABCs etc...
Python is a great language, and I always opt for it when it's an option,
but I've used it to write front-end code, and it sucks.
-- Carl Smith
carl.in...@gmail.com
On 12 August 2017 at 00:46, Alberto Berti wrote:
> >&g
fic features to
define elegant, Pythonic APIs, which is a big part of what makes the
language so nice to use.
-- Carl Smith
carl.in...@gmail.com
On 11 August 2017 at 21:58, Chris Angelico wrote:
> On Sat, Aug 12, 2017 at 6:31 AM, Alberto Berti
> wrote:
> > It's not
reasonably expect from
others, and it doesn't take much to let them know. None of this has ever
prevented me from being involved. It just prevents me from wasting other
people's time. -- Carl
-- Carl Smith
carl.in...@gmail.com
On 23 June 2017 at 21:09, Paul Moore wrote:
> O
The main reason for naming it `delimit` was to be consistent with the karg
`delimiter`, so `str.delimit(index, delimiter)`. You could call it `chop` I
guess, but I'm just bikeshedding, so will leave it while you guys figure
out the important stuff.
-- Carl Smith
carl.in...@gmail.com
On
On the block size arg, couldn't it just be named `index`?
On Tue, 2 May 2017 13:12 Carl Smith, wrote:
> Sorry. I meant to be terse, but wasn't clear enough. I meant the method
> name. If it takes a `delimiter` karg, it would be consistent to call the
> operation `delimit`
Sorry. I meant to be terse, but wasn't clear enough. I meant the method
name. If it takes a `delimiter` karg, it would be consistent to call the
operation `delimit`.
On Tue, 2 May 2017 13:06 Carl Smith, wrote:
> Couldn't it just be named `str.delimit`? I totally agree with Steve fo
Couldn't it just be named `str.delimit`? I totally agree with Steve for
what it's worth. Thanks for everything guys. Best,
On Tue, 2 May 2017 13:02 Joao S. O. Bueno, wrote:
> On 1 May 2017 at 11:04, Juancarlo Añez wrote:
> >
> > On Mon, May 1, 2017 at 9:38 AM, Nick Coghlan wrote:
> >>
> >> jus
Sorry. Ignore my last message. I thought this conversation was on the
IPython Dev list.
-- Carl Smith
carl.in...@gmail.com
On 12 April 2017 at 10:31, Carl Smith wrote:
> I actually did have `me` defined, but changed it to `my` recently. I use
> it in my shell to store my personal details
t new users
to the help they need.
-- Carl Smith
carl.in...@gmail.com
On 12 April 2017 at 04:18, Steven D'Aprano wrote:
> On Wed, Apr 12, 2017 at 09:56:40AM +0800, Kamal Mustafa wrote:
>
> > On the same theme with "import this" and "import antigravity", "
44 matches
Mail list logo