unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* 23.0.60; Can't paste from files with .arc extensions
@ 2008-03-09  0:14 Brian Adkins
  2008-03-09 20:53 ` Richard Stallman
  0 siblings, 1 reply; 20+ messages in thread
From: Brian Adkins @ 2008-03-09  0:14 UTC (permalink / raw)
  To: emacs-pretest-bug

I discovered that I could not select text with the mouse and paste via 
middle-button click into a non-emacs window when the file in question 
had a .arc extension. Paul Graham's new Arc language uses .arc as an 
extension and this extension is associated with no-conversion in the 
auto-coding-alist variable as follows:

auto-coding-alist is a variable defined in `mule.el'.
Its value is
(("\\.\\(arc\\|zip\\|lzh\\|lha\\|zoo\\|[jew]ar\\|xpi\\|exe\\|rar\\|ARC\\|ZIP\\|LZH\\|LHA\\|ZOO\\|[JEW]AR\\|XPI\\|EXE\\|RAR\\)\\'" 
. no-conversion)
  ("\\.\\(sx[dmicw]\\|odt\\|tar\\|tgz\\)\\'" . no-conversion)
  ("\\.\\(gz\\|Z\\|bz\\|bz2\\|gpg\\)\\'" . no-conversion)
  ("\\.\\(jpe?g\\|png\\|gif\\|tiff?\\|p[bpgn]m\\)\\'" . no-conversion)
  ("\\.pdf\\'" . no-conversion)
  ("/#[^/]+#\\'" . emacs-mule))

I am able to fix the problem by removing arc from the auto-coding-alist, 
but someone on gnu.emacs.help suggested I should file a bug report 
regarding this behavior.

Thanks,
Brian Adkins


In GNU Emacs 23.0.60.2 (i686-pc-linux-gnu, GTK+ Version 2.12.0)
  of 2008-02-06 on airstream
Windowing system distributor `The X.Org Foundation', version 11.0.10300000
configured using `configure  '--enable-font-backend' '--with-gif=no''

Important settings:
   value of $LC_ALL: nil
   value of $LC_COLLATE: nil
   value of $LC_CTYPE: nil
   value of $LC_MESSAGES: nil
   value of $LC_MONETARY: nil
   value of $LC_NUMERIC: nil
   value of $LC_TIME: nil
   value of $LANG: en_US.UTF-8
   value of $XMODIFIERS: nil
   locale-coding-system: utf-8-unix
   default-enable-multibyte-characters: t




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09  0:14 23.0.60; Can't paste from files with .arc extensions Brian Adkins
@ 2008-03-09 20:53 ` Richard Stallman
  2008-03-09 21:17   ` Bastien
                     ` (4 more replies)
  0 siblings, 5 replies; 20+ messages in thread
From: Richard Stallman @ 2008-03-09 20:53 UTC (permalink / raw)
  To: Brian Adkins; +Cc: emacs-pretest-bug

    Paul Graham's new Arc language uses .arc as an 
    extension

They are asking for trouble by using that extension.  They should
change the extension ASAP.

I am not sure whether we should try to make Emacs distinguish between
Arc programs and .arc archives.  If this can be done so reliably
that it never makes a mistake, then we may as well do it.  But if it
is not that reliable, better to tell all Arc programmers that they
should put -*-arc-language-*- in their files.

Is the implementation of Arc free software?





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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 20:53 ` Richard Stallman
@ 2008-03-09 21:17   ` Bastien
  2008-03-10 17:16     ` Richard Stallman
  2008-03-09 21:20   ` Eric Hanchrow
                     ` (3 subsequent siblings)
  4 siblings, 1 reply; 20+ messages in thread
From: Bastien @ 2008-03-09 21:17 UTC (permalink / raw)
  To: rms; +Cc: Brian Adkins, emacs-pretest-bug

Richard Stallman <rms@gnu.org> writes:

>     Paul Graham's new Arc language uses .arc as an 
>     extension
>
> Is the implementation of Arc free software?

Here is the copyright notice:

  This software is copyright (c) Paul Graham and Robert Morris.
  Permission to use it is granted under the Perl Foundations's 
  Artistic License 2.0.

-- 
Bastien




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 20:53 ` Richard Stallman
  2008-03-09 21:17   ` Bastien
@ 2008-03-09 21:20   ` Eric Hanchrow
  2008-03-09 21:27     ` Bastien
  2008-03-09 21:59   ` Miles Bader
                     ` (2 subsequent siblings)
  4 siblings, 1 reply; 20+ messages in thread
From: Eric Hanchrow @ 2008-03-09 21:20 UTC (permalink / raw)
  To: emacs-devel; +Cc: emacs-pretest-bug

>>>>> "Richard" == Richard Stallman <rms@gnu.org> writes:

    Richard>     Paul Graham's new Arc language uses .arc as an
    Richard>     extension

    Richard> They are asking for trouble by using that extension.
    Richard> They should change the extension ASAP.

.arcl might be a reasonable suffix.

    Richard> Is the implementation of Arc free software?


I'm not sure; their copyright file says "Permission to use it is
granted under the Perl Foundations's Artistic License 2.0."


-- 
Documentation exists, but never seems to be complete.
        -- Dennis Ritchie, 1972





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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 21:20   ` Eric Hanchrow
@ 2008-03-09 21:27     ` Bastien
  0 siblings, 0 replies; 20+ messages in thread
From: Bastien @ 2008-03-09 21:27 UTC (permalink / raw)
  To: Eric Hanchrow; +Cc: emacs-pretest-bug, emacs-devel

Eric Hanchrow <offby1@blarg.net> writes:

>>>>>> "Richard" == Richard Stallman <rms@gnu.org> writes:
>
>     Richard>     Paul Graham's new Arc language uses .arc as an
>     Richard>     extension
>
>     Richard> They are asking for trouble by using that extension.
>     Richard> They should change the extension ASAP.
>
> .arcl might be a reasonable suffix.

I'd rather suggest them .ark 

-- 
Bastien




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 20:53 ` Richard Stallman
  2008-03-09 21:17   ` Bastien
  2008-03-09 21:20   ` Eric Hanchrow
@ 2008-03-09 21:59   ` Miles Bader
  2008-03-09 22:39     ` Eli Zaretskii
                       ` (2 more replies)
  2008-03-09 22:27   ` Eli Zaretskii
  2008-03-09 23:58   ` Brian Adkins
  4 siblings, 3 replies; 20+ messages in thread
From: Miles Bader @ 2008-03-09 21:59 UTC (permalink / raw)
  To: rms; +Cc: Brian Adkins, emacs-pretest-bug

Richard Stallman <rms@gnu.org> writes:
>     Paul Graham's new Arc language uses .arc as an 
>     extension
>
> They are asking for trouble by using that extension.  They should
> change the extension ASAP.

What is the original "arc" anyway?  Are such archives common (i've never
even heard of them)?

-Miles

-- 
Selfish, adj. Devoid of consideration for the selfishness of others.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 20:53 ` Richard Stallman
                     ` (2 preceding siblings ...)
  2008-03-09 21:59   ` Miles Bader
@ 2008-03-09 22:27   ` Eli Zaretskii
  2008-03-10 17:16     ` Richard Stallman
  2008-03-09 23:58   ` Brian Adkins
  4 siblings, 1 reply; 20+ messages in thread
From: Eli Zaretskii @ 2008-03-09 22:27 UTC (permalink / raw)
  To: rms; +Cc: info, emacs-pretest-bug

> From: Richard Stallman <rms@gnu.org>
> Date: Sun, 09 Mar 2008 16:53:49 -0400
> Cc: emacs-pretest-bug@gnu.org
> 
> I am not sure whether we should try to make Emacs distinguish between
> Arc programs and .arc archives.

That's not the issue here.  The issue is that Emacs was evidently
unable to copy-paste text from such a file into another X application.

I think it's a bug.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 21:59   ` Miles Bader
@ 2008-03-09 22:39     ` Eli Zaretskii
  2008-03-09 22:50       ` Miles Bader
  2008-03-09 22:45     ` Andreas Schwab
  2008-03-10 17:15     ` Richard Stallman
  2 siblings, 1 reply; 20+ messages in thread
From: Eli Zaretskii @ 2008-03-09 22:39 UTC (permalink / raw)
  To: Miles Bader; +Cc: info, emacs-pretest-bug, rms

> From: Miles Bader <miles@gnu.org>
> Date: Mon, 10 Mar 2008 06:59:47 +0900
> Cc: Brian Adkins <info@lojic.com>, emacs-pretest-bug@gnu.org
> 
> What is the original "arc" anyway?

A very old archive format, one of the first ones.

> Are such archives common

I don't think they are, nowadays.

> (i've never even heard of them)?

Gee, Miles! you couldn't be _that_ young! ;-)




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 21:59   ` Miles Bader
  2008-03-09 22:39     ` Eli Zaretskii
@ 2008-03-09 22:45     ` Andreas Schwab
  2008-03-10 17:15     ` Richard Stallman
  2 siblings, 0 replies; 20+ messages in thread
From: Andreas Schwab @ 2008-03-09 22:45 UTC (permalink / raw)
  To: Miles Bader; +Cc: Brian Adkins, emacs-pretest-bug, rms

Miles Bader <miles@gnu.org> writes:

> What is the original "arc" anyway?

http://en.wikipedia.org/wiki/ARC_%28file_format%29

> Are such archives common (i've never even heard of them)?

You can still find some on the internet. :-)

Andreas.

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 22:39     ` Eli Zaretskii
@ 2008-03-09 22:50       ` Miles Bader
  2008-03-10  4:08         ` Eli Zaretskii
  2008-03-10 17:16         ` Richard Stallman
  0 siblings, 2 replies; 20+ messages in thread
From: Miles Bader @ 2008-03-09 22:50 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: info, emacs-pretest-bug, rms

Eli Zaretskii <eliz@gnu.org> writes:
>> What is the original "arc" anyway?
>
> A very old archive format, one of the first ones.
>
>> Are such archives common
>
> I don't think they are, nowadays.

So is it worth having emacs support that extension for them, then?
[Even if there are still a few such files lying around, what's the
likelihood someone would visit one in Emacs?]

I don't particularly care about paul graham's language (the scuttlebutt
is that it's a bit of a mess), but if his language is called "Arc", I
can hardly blame him for using that extension for the source files --
and if the previous user is only very rarely used, not care much about
the conflict.

>> (i've never even heard of them)?
>
> Gee, Miles! you couldn't be _that_ young! ;-)

No, sadly, that particular deficiency is not the cause of my
ignorance... :-(

-Miles

-- 
Scriptures, n. The sacred books of our holy religion, as distinguished from
the false and profane writings on which all other faiths are based.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 20:53 ` Richard Stallman
                     ` (3 preceding siblings ...)
  2008-03-09 22:27   ` Eli Zaretskii
@ 2008-03-09 23:58   ` Brian Adkins
  2008-03-10  8:33     ` tomas
  2008-03-10 17:16     ` Richard Stallman
  4 siblings, 2 replies; 20+ messages in thread
From: Brian Adkins @ 2008-03-09 23:58 UTC (permalink / raw)
  To: rms; +Cc: emacs-pretest-bug

Richard Stallman wrote, On 03/09/2008 04:53 PM:
 >     Paul Graham's new Arc language uses .arc as an
 >     extension
 >
 > They are asking for trouble by using that extension.  They should
 > change the extension ASAP.

What is the problem? Arc programming language files are plain text and 
archive files are binary, right? Shouldn't that be enough to distinguish 
between them?

 > I am not sure whether we should try to make Emacs distinguish between
 > Arc programs and .arc archives.  If this can be done so reliably
 > that it never makes a mistake, then we may as well do it.  But if it
 > is not that reliable, better to tell all Arc programmers that they
 > should put -*-arc-language-*- in their files.
 >
 > Is the implementation of Arc free software?
 >
 >





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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 22:50       ` Miles Bader
@ 2008-03-10  4:08         ` Eli Zaretskii
  2008-03-10 17:16         ` Richard Stallman
  1 sibling, 0 replies; 20+ messages in thread
From: Eli Zaretskii @ 2008-03-10  4:08 UTC (permalink / raw)
  To: Miles Bader; +Cc: info, emacs-pretest-bug, rms

> From: Miles Bader <miles@gnu.org>
> Cc: info@lojic.com,  emacs-pretest-bug@gnu.org,  rms@gnu.org
> Date: Mon, 10 Mar 2008 07:50:33 +0900
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> >> What is the original "arc" anyway?
> >
> > A very old archive format, one of the first ones.
> >
> >> Are such archives common
> >
> > I don't think they are, nowadays.
> 
> So is it worth having emacs support that extension for them, then?

Maybe not.

But again, I asked the OP to post the problem here because of the
failure to paste, not because of the meaning of the .arc extension.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 23:58   ` Brian Adkins
@ 2008-03-10  8:33     ` tomas
  2008-03-10 13:12       ` Brian Adkins
  2008-03-10 17:16     ` Richard Stallman
  1 sibling, 1 reply; 20+ messages in thread
From: tomas @ 2008-03-10  8:33 UTC (permalink / raw)
  To: Brian Adkins; +Cc: emacs-pretest-bug, rms

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sun, Mar 09, 2008 at 07:58:38PM -0400, Brian Adkins wrote:
> Richard Stallman wrote, On 03/09/2008 04:53 PM:
> >     Paul Graham's new Arc language uses .arc as an

[...]

> What is the problem? Arc programming language files are plain text and 
> archive files are binary, right? Shouldn't that be enough to distinguish 
> between them?

And how you distinguish between that?

Anyway -- ARC the archive format seems to have a semi-reliable magic
signature. There is a byte hex 1A at the beginning, the following byte
should be between 0 and 8[1].

But I don't know whether its worth it...

- ------------------------------------
[1] <http://arc.cvs.sourceforge.net/arc/arc/Arcinfo?revision=1.1.1.1&view=markup>

    Although the seem to expect "leading garbage" of up to 64K, which makes
    detection somewhat of a challenge :-(

Regards
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFH1PJCBcgs9XrR2kYRAr8bAJwPxavm5/ysQhcfN69JU897Ui083QCcDiKI
NqRo7+ajJ0uirXO0ed1doO8=
=5YwS
-----END PGP SIGNATURE-----




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-10  8:33     ` tomas
@ 2008-03-10 13:12       ` Brian Adkins
  0 siblings, 0 replies; 20+ messages in thread
From: Brian Adkins @ 2008-03-10 13:12 UTC (permalink / raw)
  To: tomas; +Cc: emacs-pretest-bug, rms


tomas@tuxteam.de wrote, On 03/10/2008 04:33 AM:
 > -----BEGIN PGP SIGNED MESSAGE-----
 > Hash: SHA1
 >
 > On Sun, Mar 09, 2008 at 07:58:38PM -0400, Brian Adkins wrote:
 > > Richard Stallman wrote, On 03/09/2008 04:53 PM:
 > > >     Paul Graham's new Arc language uses .arc as an
 >
 > [...]
 >
 > > What is the problem? Arc programming language files are plain text and
 > > archive files are binary, right? Shouldn't that be enough to 
distinguish
 > > between them?
 >
 > And how you distinguish between that?

Show me an archive file that could be confused for an Arc programming 
language file.

Anyway, it's moot for me at this point; I've already removed .arc from 
auto-coding-alist and that works fine for me.





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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 21:59   ` Miles Bader
  2008-03-09 22:39     ` Eli Zaretskii
  2008-03-09 22:45     ` Andreas Schwab
@ 2008-03-10 17:15     ` Richard Stallman
  2 siblings, 0 replies; 20+ messages in thread
From: Richard Stallman @ 2008-03-10 17:15 UTC (permalink / raw)
  To: Miles Bader; +Cc: info, emacs-pretest-bug

    What is the original "arc" anyway?  Are such archives common (i've never
    even heard of them)?

I think they are not very common any more, but we don't want to break them.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 22:27   ` Eli Zaretskii
@ 2008-03-10 17:16     ` Richard Stallman
  2008-03-12  4:30       ` Eli Zaretskii
  0 siblings, 1 reply; 20+ messages in thread
From: Richard Stallman @ 2008-03-10 17:16 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: info, emacs-pretest-bug

    That's not the issue here.  The issue is that Emacs was evidently
    unable to copy-paste text from such a file into another X application.

Maybe that is a real bug, but we can't tell for certain from the cose
of an Arc program that was treated as an archive.  ARC mode probably
gets confused if the file is not an archive.  Maybe that confusion
is the cause of the other problem.

So the next step is to see if the cut and paste problem happens with a
file that is being visited in the right mode: either an Arc program
visited in the right mode for an Arc program, or a real ARC archive
visited in ARC mode.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 23:58   ` Brian Adkins
  2008-03-10  8:33     ` tomas
@ 2008-03-10 17:16     ` Richard Stallman
  1 sibling, 0 replies; 20+ messages in thread
From: Richard Stallman @ 2008-03-10 17:16 UTC (permalink / raw)
  To: Brian Adkins; +Cc: emacs-pretest-bug

    What is the problem? Arc programming language files are plain text and 
    archive files are binary, right? Shouldn't that be enough to distinguish 
    between them?

I do not know whether it can be done reliably in that way.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 22:50       ` Miles Bader
  2008-03-10  4:08         ` Eli Zaretskii
@ 2008-03-10 17:16         ` Richard Stallman
  1 sibling, 0 replies; 20+ messages in thread
From: Richard Stallman @ 2008-03-10 17:16 UTC (permalink / raw)
  To: Miles Bader; +Cc: info, emacs-pretest-bug, eliz

    I don't particularly care about paul graham's language (the scuttlebutt
    is that it's a bit of a mess), but if his language is called "Arc", I
    can hardly blame him for using that extension for the source files --

I can blame him.  He should pick an unused extension rather than
overloading an old one.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-09 21:17   ` Bastien
@ 2008-03-10 17:16     ` Richard Stallman
  0 siblings, 0 replies; 20+ messages in thread
From: Richard Stallman @ 2008-03-10 17:16 UTC (permalink / raw)
  To: Bastien; +Cc: info, emacs-pretest-bug

    Here is the copyright notice:

      This software is copyright (c) Paul Graham and Robert Morris.
      Permission to use it is granted under the Perl Foundations's 
      Artistic License 2.0.

That is free software.




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

* Re: 23.0.60; Can't paste from files with .arc extensions
  2008-03-10 17:16     ` Richard Stallman
@ 2008-03-12  4:30       ` Eli Zaretskii
  0 siblings, 0 replies; 20+ messages in thread
From: Eli Zaretskii @ 2008-03-12  4:30 UTC (permalink / raw)
  To: rms; +Cc: info, emacs-pretest-bug

> From: Richard Stallman <rms@gnu.org>
> CC: info@lojic.com, emacs-pretest-bug@gnu.org
> Date: Mon, 10 Mar 2008 13:16:10 -0400
> 
>     That's not the issue here.  The issue is that Emacs was evidently
>     unable to copy-paste text from such a file into another X application.
> 
> Maybe that is a real bug, but we can't tell for certain from the cose
> of an Arc program that was treated as an archive.  ARC mode probably
> gets confused if the file is not an archive.  Maybe that confusion
> is the cause of the other problem.
> 
> So the next step is to see if the cut and paste problem happens with a
> file that is being visited in the right mode: either an Arc program
> visited in the right mode for an Arc program, or a real ARC archive
> visited in ARC mode.

All I can say is that I could not reproduce this on GNU/Linux and on
MS-Windows.  I created a text file named foo.arc, and then visited it
in Emacs.  Visiting it caused an error message from arc-mode.el
(saying the buffer format is not recognizable), which is expected.,
and the buffer was left in unibyte state (also expected).  But pasting
worked as I expect in that buffer: printable characters were pasted
into other applications, while non-printables were not.

So I'm unsure how to proceed with this, as it seems Emacs works
correctly for me.




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

end of thread, other threads:[~2008-03-12  4:30 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-09  0:14 23.0.60; Can't paste from files with .arc extensions Brian Adkins
2008-03-09 20:53 ` Richard Stallman
2008-03-09 21:17   ` Bastien
2008-03-10 17:16     ` Richard Stallman
2008-03-09 21:20   ` Eric Hanchrow
2008-03-09 21:27     ` Bastien
2008-03-09 21:59   ` Miles Bader
2008-03-09 22:39     ` Eli Zaretskii
2008-03-09 22:50       ` Miles Bader
2008-03-10  4:08         ` Eli Zaretskii
2008-03-10 17:16         ` Richard Stallman
2008-03-09 22:45     ` Andreas Schwab
2008-03-10 17:15     ` Richard Stallman
2008-03-09 22:27   ` Eli Zaretskii
2008-03-10 17:16     ` Richard Stallman
2008-03-12  4:30       ` Eli Zaretskii
2008-03-09 23:58   ` Brian Adkins
2008-03-10  8:33     ` tomas
2008-03-10 13:12       ` Brian Adkins
2008-03-10 17:16     ` Richard Stallman

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).