bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#38426: 27.0.50; [PATCH] * python.el: new function python-shell-send-


From: Eli Zaretskii
Subject: bug#38426: 27.0.50; [PATCH] * python.el: new function python-shell-send-statement
Date: Sat, 14 Dec 2019 14:17:16 +0200

> From: <lin.sun@zoom.us>
> Date: Fri, 29 Nov 2019 16:40:55 +0800
> 
> >From 61db0e91094297ddca302eaf691cf5b4ff82ebf6 Mon Sep 17 00:00:00 2001
> From: "lin.sun" <lin.sun@zoom.us>
> Date: Fri, 29 Nov 2019 03:10:12 -0500
> Subject: [PATCH] * python.el: new function python-shell-send-statement
> 
> Add new function `python-shell-send-statement' and bind to key "C-c
> C-e" for sending statement under cursor to inferior Python process.

Thanks.  A few comments below:

> +(defun python-shell-send-statement (&optional send-main msg)
> +  "Send the statement delimited by `python-nav-beginning-of-statement' and

The first line of a doc string should be a complete sentence, and it
should mention the function's arguments.

> +`python-nav-end-of-statement' to inferior Python process. When optional
                                                           ^^
Our convention is to leave 2 spaces between sentences in documentation
and comments, per US English rules.

> +                                                         When optional
> +argument MSG is non-nil, forces display of a user-friendly message if
> there's
> +no process running; default to t when called interactively. If there is
> region
> +be activated, it present as `python-shell-send-region'."

These lines are too long, please wrap them to make them shorter,
preferably no more than 75 characters.

Please also provide a ChangeLog style commit log message, as described
in CONTRIBUTE, and please mention the bug number there.

And finally, this new command needs to be mentioned in NEWS, under
"Python mode".

Thanks.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]