all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Sam Steingold <sds@gnu.org>
To: emacs-devel@gnu.org, Roland Winkler <winkler@gnu.org>
Subject: Re: master 70341cab3e: string-equal-ignore-case: new function
Date: Tue, 26 Jul 2022 15:44:48 -0400	[thread overview]
Message-ID: <lz8rof1wwf.fsf@3c22fb11fdab.ant.amazon.com> (raw)
In-Reply-To: <87wnbz1yxm.fsf@gnu.org> (Roland Winkler's message of "Tue, 26 Jul 2022 14:00:53 -0500")

> * Roland Winkler <jvaxyre@tah.bet> [2022-07-26 14:00:53 -0500]:
>
> On Tue, Jul 26 2022, Sam Steingold wrote:
>> +(defun string-equal-ignore-case (string1 string2)
>> +  "Like `string-equal', but case-insensitive.
>> +Upper-case and lower-case letters are treated as equal.
>> +Unibyte strings are converted to multibyte for comparison."
>> +  (eq t (compare-strings string1 0 nil string2 0 nil t)))
>
> Isn't this a perfect candidate for an inline function,
> i.e., defsubst instead of defun?

Probably...
I can probably add more declarations...

-- 
Sam Steingold (http://sds.podval.org/) on darwin Ns 10.3.2113
http://childpsy.net http://calmchildstories.com http://steingoldpsychology.com
https://www.peaceandtolerance.org/ https://camera.org
Whether pronounced "leenooks" or "line-uks", it's better than Windows.



      reply	other threads:[~2022-07-26 19:44 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <165885780615.5477.9618918327695992186@vcs2.savannah.gnu.org>
     [not found] ` <20220726175007.02EE9C00095@vcs2.savannah.gnu.org>
2022-07-26 17:58   ` master 70341cab3e: string-equal-ignore-case: new function Lars Ingebrigtsen
2022-07-26 18:21     ` Sam Steingold
2022-07-26 19:00   ` Roland Winkler
2022-07-26 19:44     ` Sam Steingold [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=lz8rof1wwf.fsf@3c22fb11fdab.ant.amazon.com \
    --to=sds@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=winkler@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.