Skip to content

Commit 978cd90

Browse files
committed
Adjust json dependency to match ruby 1.9.2 and try to load a newer json gem, if available
1 parent 8e09447 commit 978cd90

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

Rakefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ Depending on your version of ruby, you may need to install ruby rdoc/ri data:
4040
self.clean_globs += PARSER_FILES
4141

4242
require_ruby_version '>= 1.8.7'
43-
extra_deps << ['json', '~> 1.5']
43+
extra_deps << ['json', '~> 1.4']
4444
extra_dev_deps << ['racc', '~> 1.4']
4545
extra_dev_deps << ['minitest', '~> 2']
4646
extra_dev_deps << ['ZenTest', '~> 4']

lib/rdoc/text.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@
88
##
99
# For RDoc::Text#snippet
1010

11+
begin
12+
gem 'json'
13+
rescue Gem::LoadError
14+
end
15+
1116
require 'json'
1217

1318
##

0 commit comments

Comments
 (0)