diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-02 05:24:33 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-02 05:24:33 +0000 |
commit | 2df7054c3035b7c75d5a5e029f7928bd39374592 (patch) | |
tree | 15830d4b1b4391370245fdf897ab368e5cc07b0d | |
parent | 30527783c73c369b915d31127d4837378ce1a457 (diff) | |
download | ruby-2df7054c3035b7c75d5a5e029f7928bd39374592.tar.gz |
* lib/rdoc/rdoc.rb (RDoc::RDoc#parse_files): emacs local variables
are delimited by a semicolon. supported Vim style. reapplied
r24988 with fixing a typo for shebang.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27183 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | lib/rdoc/rdoc.rb | 2 |
2 files changed, 7 insertions, 1 deletions
@@ -1,3 +1,9 @@ +Fri Apr 2 14:24:27 2010 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * lib/rdoc/rdoc.rb (RDoc::RDoc#parse_files): emacs local variables + are delimited by a semicolon. supported Vim style. reapplied + r24988 with fixing a typo for shebang. + Fri Apr 2 14:16:54 2010 Nobuyoshi Nakada <nobu@ruby-lang.org> * lib/rdoc/parser/ruby.rb (RDoc::Parser::Ruby): parse also rdoc diff --git a/lib/rdoc/rdoc.rb b/lib/rdoc/rdoc.rb index 230639fb0c..10daefd5b9 100644 --- a/lib/rdoc/rdoc.rb +++ b/lib/rdoc/rdoc.rb @@ -387,7 +387,7 @@ The internal error was: end if defined? Encoding then - if /coding:\s*([\w-]+)/i =~ content[/\A(?:.*\n){0,2}/] + if /coding[=:]\s*([^\s;]+)/i =~ content[%r"\A(?:#!.*\n)?.*\n"] if enc = ::Encoding.find($1) content.force_encoding(enc) end |