ruby-changes:20068
From: drbrain <ko1@a...>
Date: Thu, 16 Jun 2011 14:22:47 +0900 (JST)
Subject: [ruby-changes:20068] drbrain:r32115 (trunk): * lib/rdoc.rb: Import RDoc 3.7 release candidate
drbrain 2011-06-16 13:59:24 +0900 (Thu, 16 Jun 2011) New Revision: 32115 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=32115 Log: * lib/rdoc.rb: Import RDoc 3.7 release candidate Added files: trunk/lib/rdoc/markup/indented_paragraph.rb trunk/lib/rdoc/rubygems_hook.rb trunk/test/rdoc/test_rdoc_markup_indented_paragraph.rb trunk/test/rdoc/test_rdoc_rubygems_hook.rb Modified files: trunk/ChangeLog trunk/lib/rdoc/any_method.rb trunk/lib/rdoc/attr.rb trunk/lib/rdoc/class_module.rb trunk/lib/rdoc/code_object.rb trunk/lib/rdoc/context.rb trunk/lib/rdoc/generator/markup.rb trunk/lib/rdoc/generator/ri.rb trunk/lib/rdoc/generator/template/darkfish/rdoc.css trunk/lib/rdoc/known_classes.rb trunk/lib/rdoc/markup/document.rb trunk/lib/rdoc/markup/formatter.rb trunk/lib/rdoc/markup/formatter_test_case.rb trunk/lib/rdoc/markup/parser.rb trunk/lib/rdoc/markup/pre_process.rb trunk/lib/rdoc/markup/to_ansi.rb trunk/lib/rdoc/markup/to_bs.rb trunk/lib/rdoc/markup/to_html.rb trunk/lib/rdoc/markup/to_html_crossref.rb trunk/lib/rdoc/markup/to_rdoc.rb trunk/lib/rdoc/markup/to_test.rb trunk/lib/rdoc/markup/to_tt_only.rb trunk/lib/rdoc/markup.rb trunk/lib/rdoc/parser/c.rb trunk/lib/rdoc/parser/ruby.rb trunk/lib/rdoc/rdoc.rb trunk/lib/rdoc/ri/driver.rb trunk/lib/rdoc/ri/store.rb trunk/lib/rdoc/text.rb trunk/lib/rdoc/top_level.rb trunk/lib/rdoc.rb trunk/test/rdoc/test_rdoc_any_method.rb trunk/test/rdoc/test_rdoc_attr.rb trunk/test/rdoc/test_rdoc_class_module.rb trunk/test/rdoc/test_rdoc_code_object.rb trunk/test/rdoc/test_rdoc_context.rb trunk/test/rdoc/test_rdoc_generator_ri.rb trunk/test/rdoc/test_rdoc_markup.rb trunk/test/rdoc/test_rdoc_markup_document.rb trunk/test/rdoc/test_rdoc_markup_paragraph.rb trunk/test/rdoc/test_rdoc_markup_pre_process.rb trunk/test/rdoc/test_rdoc_markup_to_ansi.rb trunk/test/rdoc/test_rdoc_markup_to_bs.rb trunk/test/rdoc/test_rdoc_markup_to_html.rb trunk/test/rdoc/test_rdoc_markup_to_rdoc.rb trunk/test/rdoc/test_rdoc_markup_to_tt_only.rb trunk/test/rdoc/test_rdoc_parser_c.rb trunk/test/rdoc/test_rdoc_parser_ruby.rb trunk/test/rdoc/test_rdoc_rdoc.rb trunk/test/rdoc/test_rdoc_ri_driver.rb trunk/test/rdoc/test_rdoc_ri_store.rb trunk/test/rdoc/test_rdoc_stats.rb trunk/test/rdoc/test_rdoc_text.rb trunk/test/rdoc/test_rdoc_top_level.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 32114) +++ ChangeLog (revision 32115) @@ -1,3 +1,7 @@ +Thu Jun 16 13:25:25 2011 Eric Hodel <drbrain@s...> + + * lib/rdoc*: Import RDoc 3.7 release candidate + Thu Jun 16 11:35:09 2011 Shugo Maeda <shugo@r...> * lib/net/imap.rb (search_response): parses SEARCH responses from Index: lib/rdoc.rb =================================================================== --- lib/rdoc.rb (revision 32114) +++ lib/rdoc.rb (revision 32115) @@ -27,7 +27,8 @@ # * If you want to use RDoc to create documentation for your Ruby source files, # see RDoc::Markup and refer to <tt>rdoc --help</tt> for command line # usage. -# * If you want to generate documentation for extensions written in C, see +# * If you want to write documentation for Ruby files see RDoc::Parser::Ruby +# * If you want to write documentation for extensions written in C see # RDoc::Parser::C # * If you want to generate documentation using <tt>rake</tt> see RDoc::Task. # * If you want to drive RDoc programmatically, see RDoc::RDoc. @@ -103,7 +104,7 @@ ## # RDoc version you are using - VERSION = '3.6.1' + VERSION = '3.7' ## # Method visibilities Index: lib/rdoc/context.rb =================================================================== --- lib/rdoc/context.rb (revision 32114) +++ lib/rdoc/context.rb (revision 32115) @@ -30,9 +30,9 @@ attr_reader :constants ## - # Current section of documentation + # Sets the current documentation section of documentation - attr_accessor :current_section + attr_writer :current_section ## # Files this context is found in @@ -60,6 +60,11 @@ attr_reader :requires ## + # Use this section for the next method, attribute or constant added. + + attr_accessor :temporary_section + + ## # Hash <tt>old_name => [aliases]</tt>, for aliases # that haven't (yet) been resolved to a method/attribute. # (Not to be confused with the aliases of the context.) @@ -186,10 +191,7 @@ end def inspect # :nodoc: - "#<%s:0x%x %s %p>" % [ - self.class, object_id, - @sequence, title - ] + "#<%s:0x%x %p>" % [self.class, object_id, title] end ## @@ -216,6 +218,7 @@ @current_section = Section.new self, nil, nil @sections = { nil => @current_section } + @temporary_section = nil @classes = {} @modules = {} @@ -287,22 +290,32 @@ # TODO find a policy for 'attr_reader :foo' + 'def foo=()' register = false - if attribute.rw.index('R') then + key = nil + + if attribute.rw.index 'R' then key = attribute.pretty_name known = @methods_hash[key] + if known then known.comment = attribute.comment if known.comment.empty? + elsif registered = @methods_hash[attribute.pretty_name << '='] and + RDoc::Attr === registered then + registered.rw = 'RW' else(... truncated) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/