all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#33804: [PATCH] * src/editfns.c (insert-char): Skip unnecessary fixnum check
@ 2018-12-19 16:48 Nicholas Drozd
  2018-12-19 16:57 ` Paul Eggert
  0 siblings, 1 reply; 2+ messages in thread
From: Nicholas Drozd @ 2018-12-19 16:48 UTC (permalink / raw)
  To: 33804

COUNT gets set to 1 when it is passed in as nil, and in that case
there is no need to check its type.
---
 src/editfns.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/editfns.c b/src/editfns.c
index 8df4ed107e..9bfab74a9a 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -1471,7 +1471,8 @@ called interactively, INHERIT is t.  */)
   CHECK_CHARACTER (character);
   if (NILP (count))
     XSETFASTINT (count, 1);
-  CHECK_FIXNUM (count);
+  else
+    CHECK_FIXNUM (count);
   c = XFIXNAT (character);

   if (!NILP (BVAR (current_buffer, enable_multibyte_characters)))
-- 
2.17.1





^ permalink raw reply related	[flat|nested] 2+ messages in thread

* bug#33804: [PATCH] * src/editfns.c (insert-char): Skip unnecessary fixnum check
  2018-12-19 16:48 bug#33804: [PATCH] * src/editfns.c (insert-char): Skip unnecessary fixnum check Nicholas Drozd
@ 2018-12-19 16:57 ` Paul Eggert
  0 siblings, 0 replies; 2+ messages in thread
From: Paul Eggert @ 2018-12-19 16:57 UTC (permalink / raw)
  To: Nicholas Drozd; +Cc: 33804-done

Thanks, I installed that into master in your name.






^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-12-19 16:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-12-19 16:48 bug#33804: [PATCH] * src/editfns.c (insert-char): Skip unnecessary fixnum check Nicholas Drozd
2018-12-19 16:57 ` Paul Eggert

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.