unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Kangas <stefankangas@gmail.com>
To: Andrea Corallo <acorallo@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: Hard-to-understand line in xfaces.c
Date: Mon, 22 Jul 2024 08:55:52 -0700	[thread overview]
Message-ID: <CADwFkmnXgCy80qCOYo3BKn0tEwTqWP+-LSCPd8LzUA+dGU=ykg@mail.gmail.com> (raw)
In-Reply-To: <yp1ttghze8p.fsf@fencepost.gnu.org>

Andrea Corallo <acorallo@gnu.org> writes:

> Stefan Kangas <stefankangas@gmail.com> writes:
>
>> Could someone explain this line in xfaces.c:7184?
>>
>>     len -= 0 < len && name[len - 1] == '\n';
>>
>> It seems rather mysterious to me; for example, does it actually do
>> anything?
>
> If len is greater than zero and name[len - 1] is '\n' then is decreasing
> len by one.

Doh!  Thanks for clearing it up for me.



  parent reply	other threads:[~2024-07-22 15:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-22 14:20 Hard-to-understand line in xfaces.c Stefan Kangas
2024-07-22 14:35 ` Andrea Corallo
2024-07-22 14:59   ` Eli Zaretskii
2024-07-22 15:55   ` Stefan Kangas [this message]
2024-07-22 14:38 ` Pip Cet

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to='CADwFkmnXgCy80qCOYo3BKn0tEwTqWP+-LSCPd8LzUA+dGU=ykg@mail.gmail.com' \
    --to=stefankangas@gmail.com \
    --cc=acorallo@gnu.org \
    --cc=emacs-devel@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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).