GNU bug report logs - #7500
24.0.50; doc string of `current-kill'

Previous Next

Package: emacs;

Reported by: "Drew Adams" <drew.adams <at> oracle.com>

Date: Sat, 27 Nov 2010 17:15:02 UTC

Severity: minor

Tags: fixed

Found in version 24.0.50

Fixed in version 24.1

Done: Lars Magne Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 7500 in the body.
You can then email your comments to 7500 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Sat, 27 Nov 2010 17:15:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to "Drew Adams" <drew.adams <at> oracle.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sat, 27 Nov 2010 17:15:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: "Drew Adams" <drew.adams <at> oracle.com>
To: <bug-gnu-emacs <at> gnu.org>
Subject: 24.0.50; doc string of `current-kill'
Date: Sat, 27 Nov 2010 09:18:17 -0800
Please split this long sentence, and make it comprehensible:

 "If N is zero, `interprogram-paste-function' is set, and calling
  it returns a string or list of strings, then that string (or
  list) is added to the front of the kill ring and the string (or
  first string in the list) is returned as the latest kill."

`interprogram-paste-function' is set to what? to the kill-ring head?

Is "and calling it returns..." a statement of one of the _consequences_
of N being 0, or is it a further condition for what follows: "then that
string..." - i.e. "AND _IF_ calling it results... then..."?





Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Sat, 27 Nov 2010 18:12:02 GMT) Full text and rfc822 format available.

Message #8 received at 7500 <at> debbugs.gnu.org (full text, mbox):

From: Andreas Schwab <schwab <at> linux-m68k.org>
To: "Drew Adams" <drew.adams <at> oracle.com>
Cc: 7500 <at> debbugs.gnu.org
Subject: Re: bug#7500: 24.0.50; doc string of `current-kill'
Date: Sat, 27 Nov 2010 19:16:56 +0100
"Drew Adams" <drew.adams <at> oracle.com> writes:

> Please split this long sentence, and make it comprehensible:
>
>  "If N is zero, `interprogram-paste-function' is set, and calling
>   it returns a string or list of strings, then that string (or
>   list) is added to the front of the kill ring and the string (or
>   first string in the list) is returned as the latest kill."
>
> `interprogram-paste-function' is set to what?

interprogram-paste-function should be set to a function, otherwise it
wouldn't be called interprogram-paste-function.

> to the kill-ring head?

Since when is the kill-ring head a function?

> Is "and calling it returns..." a statement of one of the _consequences_
> of N being 0, or is it a further condition for what follows: "then that
> string..." - i.e. "AND _IF_ calling it results... then..."?

"then" starts a consequence, not "and".

Andreas.

-- 
Andreas Schwab, schwab <at> linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Sat, 27 Nov 2010 18:34:01 GMT) Full text and rfc822 format available.

Message #11 received at 7500 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: "Drew Adams" <drew.adams <at> oracle.com>
Cc: 7500 <at> debbugs.gnu.org
Subject: Re: bug#7500: 24.0.50; doc string of `current-kill'
Date: Sat, 27 Nov 2010 13:39:16 -0500
> Please split this long sentence, and make it comprehensible:
>  "If N is zero, `interprogram-paste-function' is set, and calling

The above is parsed as

   (and "if N is zero"
        "`interprogram-paste-function' is set"
        "calling ...")

since (and A B C) is usually written in (US) English "A, B, and C".
How 'bout:

 "If N is zero and `interprogram-paste-function' is set to a function
  that returns a string or list of strings, then that string (or
  list) is added to the front of the kill ring and the string (or
  first string in the list) is returned as the latest kill."


        Stefan




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Sat, 27 Nov 2010 19:17:02 GMT) Full text and rfc822 format available.

Message #14 received at 7500 <at> debbugs.gnu.org (full text, mbox):

From: "Drew Adams" <drew.adams <at> oracle.com>
To: "'Andreas Schwab'" <schwab <at> linux-m68k.org>
Cc: 7500 <at> debbugs.gnu.org
Subject: RE: bug#7500: 24.0.50; doc string of `current-kill'
Date: Sat, 27 Nov 2010 11:19:40 -0800
> interprogram-paste-function should be set to a function, otherwise it
> wouldn't be called interprogram-paste-function.
... 
> Since when is the kill-ring head a function?
...
> "then" starts a consequence, not "and".

Stop trying to justify it.  It is a rambling, confusing sentence.

It reads like a translation to English from some long sentence that might (or
might not) have been clear in some other language (perhaps one that revels in
long sentences?).  The result is not clear.

I can't even tell whether (a) "then" here is part of an "if...then" construct or
(b) there is a comma splice (no-no) and "then" here is a _temporal_ adverb
starting an independent clause.  In the latter case, the comma should be a
period and "then" should start a new sentence.

If you don't know where to begin to improve the text, start by splitting it into
shorter, simpler sentences, preferably in the active voice.  That will probably
make the meaning clear.

Once I have the meaning I can propose something, if needed.  But my guess is
that once you've changed to active, short sentences the meaning will be clear
enough for everyone - no further improvement needed.





Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Sat, 27 Nov 2010 19:31:02 GMT) Full text and rfc822 format available.

Message #17 received at 7500 <at> debbugs.gnu.org (full text, mbox):

From: "Drew Adams" <drew.adams <at> oracle.com>
To: "'Stefan Monnier'" <monnier <at> IRO.UMontreal.CA>
Cc: 7500 <at> debbugs.gnu.org
Subject: RE: bug#7500: 24.0.50; doc string of `current-kill'
Date: Sat, 27 Nov 2010 11:34:02 -0800
> >  "If N is zero, `interprogram-paste-function' is set, and calling
> 
> The above is parsed as
>    (and "if N is zero"
>         "`interprogram-paste-function' is set"
>         "calling ...")

Thank you!  That's just the kind of succinct statement that makes the meaning
clear and advances the schmilblick.

But if that is the meaning then we also need to document what happens if N is
zero and one of the other conjuncts is false.  Are you sure you don't mean the
following instead?

 When N is zero, if i-p-f is set then calling...

IOW, _IF_ N is zero then (if `i-p-f' is....) else ZZZ.
(We already say what happens when N is not zero (ZZZ).)

> since (and A B C) is usually written in (US) English "A, B, and C".
> How 'bout:
> 
>  "If N is zero and `interprogram-paste-function' is set to a function
>   that returns a string or list of strings, then that string (or
>   list) is added to the front of the kill ring and the string (or
>   first string in the list) is returned as the latest kill."

See above.  If my guess above is correct, then:

 When N is zero, if `i-p-f' is set to...

And since the return value of i-p-a is _supposed_ to be either nil or a
string-or-list-of-strings:

 When N is zero, call the value of `interprogram-paste-function'.
 If that call returns nil, do nothing more and return the
 kill-ring car (??).  Otherwise, prepend the returned string
 (or list of strings) to the kill ring and then return the new
 kill-ring car.

See "??" above.  What does `current-kill' return if `i-p-f' returns nil when
called? the existing kill-ring head? nil?





Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Sat, 27 Nov 2010 20:23:01 GMT) Full text and rfc822 format available.

Message #20 received at 7500 <at> debbugs.gnu.org (full text, mbox):

From: Andreas Schwab <schwab <at> linux-m68k.org>
To: "Drew Adams" <drew.adams <at> oracle.com>
Cc: 7500 <at> debbugs.gnu.org
Subject: Re: bug#7500: 24.0.50; doc string of `current-kill'
Date: Sat, 27 Nov 2010 21:28:00 +0100
"Drew Adams" <drew.adams <at> oracle.com> writes:

>> interprogram-paste-function should be set to a function, otherwise it
>> wouldn't be called interprogram-paste-function.
> ... 
>> Since when is the kill-ring head a function?
> ...
>> "then" starts a consequence, not "and".
>
> Stop trying to justify it.

It was already left justfied.

Andreas.

-- 
Andreas Schwab, schwab <at> linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Thu, 14 Jul 2011 15:08:03 GMT) Full text and rfc822 format available.

Message #23 received at 7500 <at> debbugs.gnu.org (full text, mbox):

From: Lars Magne Ingebrigtsen <larsi <at> gnus.org>
To: "Drew Adams" <drew.adams <at> oracle.com>
Cc: 'Stefan Monnier' <monnier <at> IRO.UMontreal.CA>, 7500 <at> debbugs.gnu.org
Subject: Re: bug#7500: 24.0.50; doc string of `current-kill'
Date: Thu, 14 Jul 2011 17:01:59 +0200
"Drew Adams" <drew.adams <at> oracle.com> writes:

> And since the return value of i-p-a is _supposed_ to be either nil or a
> string-or-list-of-strings:
>
>  When N is zero, call the value of `interprogram-paste-function'.
>  If that call returns nil, do nothing more and return the
>  kill-ring car (??).  Otherwise, prepend the returned string
>  (or list of strings) to the kill ring and then return the new
>  kill-ring car.
>
> See "??" above.  What does `current-kill' return if `i-p-f' returns nil when
> called? the existing kill-ring head? nil?

Looking at the code, if it returns nil, then the entire "When" statement
fails.  I'll try to work that in...  somehow...

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7500; Package emacs. (Thu, 14 Jul 2011 15:08:03 GMT) Full text and rfc822 format available.

Message #26 received at 7500 <at> debbugs.gnu.org (full text, mbox):

From: Lars Magne Ingebrigtsen <larsi <at> gnus.org>
To: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
Cc: 7500 <at> debbugs.gnu.org, Drew Adams <drew.adams <at> oracle.com>
Subject: Re: bug#7500: 24.0.50; doc string of `current-kill'
Date: Thu, 14 Jul 2011 17:01:19 +0200
Stefan Monnier <monnier <at> IRO.UMontreal.CA> writes:

> How 'bout:
>
>  "If N is zero and `interprogram-paste-function' is set to a function
>   that returns a string or list of strings, then that string (or
>   list) is added to the front of the kill ring and the string (or
>   first string in the list) is returned as the latest kill."

I've now added this.

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/




Added tag(s) fixed. Request was from Lars Magne Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Thu, 14 Jul 2011 15:08:04 GMT) Full text and rfc822 format available.

bug marked as fixed in version 24.1, send any further explanations to 7500 <at> debbugs.gnu.org and "Drew Adams" <drew.adams <at> oracle.com> Request was from Lars Magne Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Thu, 14 Jul 2011 15:08:04 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 12 Aug 2011 11:24:03 GMT) Full text and rfc822 format available.

This bug report was last modified 14 years ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.