[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ruby-mode : ruby-mode-set-encoding

From: Paul R
Subject: Re: ruby-mode : ruby-mode-set-encoding
Date: Wed, 04 Mar 2009 09:25:24 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.90 (gnu/linux)

Hello Nobuyoshi,

Nobuyoshi> It's mandatory for Ruby 1.9 or later. Ruby 1.9 needs that
Nobuyoshi> "magic comment" to know in what encoding a script is written.
Nobuyoshi> Otherwise, the script is assumed as written with ASCII 7bit
Nobuyoshi> characters only, and non-ASCII character causes an exception
Nobuyoshi> if exists.

Fine, I did not relate it to 1.9 (that was recently released) because
I have seen this behaviour for monthes. I think the reason is that I was
using the svn version of ruby-mode.el. After reading the doc, it is
clear and I see indeed why now ruby wants to know file encoding before
parsing it.

Nobuyoshi> Could you elaborate the problem?

The problem simply was that I did not expect this behaviour, and did not
understand the motivation behind it.

Somebody mentionned some similarities with python. Should emacs provide
a standard mechanism to insert this tag for script language modes that
need it ?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]