diff options
author | hsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-11-05 09:18:10 +0000 |
---|---|---|
committer | hsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-11-05 09:18:10 +0000 |
commit | cdc527db342eda4c58b62c5dc2a14441a395df5d (patch) | |
tree | 237c953b345a00333d1600706a7f2484b4ad408c /lib/rdoc/rdoc.rb | |
parent | 0a0eb2807ed745e1cdf7f4698fe805b4aaaee2c6 (diff) |
* lib/rdoc/*, test/rdoc/*: Update rdoc-5.0.0
Release note: https://github.com/rdoc/rdoc/blob/b825775647f62c5b525e9780a28ff2fbb1d5bf6f/History.rdoc#500--2016-11-05
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rdoc/rdoc.rb')
-rw-r--r-- | lib/rdoc/rdoc.rb | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/lib/rdoc/rdoc.rb b/lib/rdoc/rdoc.rb index ec50d8eba5..adcb65b13b 100644 --- a/lib/rdoc/rdoc.rb +++ b/lib/rdoc/rdoc.rb @@ -161,15 +161,9 @@ class RDoc::RDoc RDoc.load_yaml - parse_error = if Object.const_defined? :Psych then - Psych::SyntaxError - else - ArgumentError - end - begin options = YAML.load_file '.rdoc_options' - rescue *parse_error + rescue Psych::SyntaxError end raise RDoc::Error, "#{options_file} is not a valid rdoc options file" unless @@ -417,6 +411,7 @@ The internal error was: return [] if file_list.empty? + original_options = @options.dup @stats.begin_adding file_info = file_list.map do |filename| @@ -425,6 +420,7 @@ The internal error was: end.compact @stats.done_adding + @options = original_options file_info end @@ -479,7 +475,7 @@ The internal error was: @last_modified = setup_output_dir @options.op_dir, @options.force_update end - @store.encoding = @options.encoding if @options.respond_to? :encoding + @store.encoding = @options.encoding @store.dry_run = @options.dry_run @store.main = @options.main_page @store.title = @options.title |