ruby-changes:17713
From: marcandre <ko1@a...>
Date: Tue, 9 Nov 2010 05:58:38 +0900 (JST)
Subject: [ruby-changes:17713] Ruby:r29724 (trunk): * lib/rdoc/*.rb: Remove unused variable warnings.
marcandre 2010-11-09 05:58:28 +0900 (Tue, 09 Nov 2010) New Revision: 29724 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=29724 Log: * lib/rdoc/*.rb: Remove unused variable warnings. Patch by Run Paint [ruby-core:30991] Modified files: trunk/lib/rdoc/generator/darkfish.rb trunk/lib/rdoc/markup/attribute_manager.rb trunk/lib/rdoc/markup/parser.rb trunk/lib/rdoc/parser/c.rb trunk/lib/rdoc/parser/ruby.rb trunk/lib/rdoc/rdoc.rb trunk/lib/rdoc/ruby_lex.rb Index: lib/rdoc/generator/darkfish.rb =================================================================== --- lib/rdoc/generator/darkfish.rb (revision 29723) +++ lib/rdoc/generator/darkfish.rb (revision 29724) @@ -277,7 +277,6 @@ outfile = @outputdir + file.path debug_msg " working on %s (%s)" % [ file.full_name, outfile ] rel_prefix = @outputdir.relative_path_from( outfile.dirname ) - context = binding() debug_msg " rendering #{outfile}" self.render_template( template_file, binding(), outfile ) Index: lib/rdoc/rdoc.rb =================================================================== --- lib/rdoc/rdoc.rb (revision 29723) +++ lib/rdoc/rdoc.rb (revision 29724) @@ -383,8 +383,6 @@ @generator = gen_klass.for @options - pwd = Dir.pwd - Dir.chdir @options.op_dir do begin self.class.current = self Index: lib/rdoc/markup/parser.rb =================================================================== --- lib/rdoc/markup/parser.rb (revision 29723) +++ lib/rdoc/markup/parser.rb (revision 29724) @@ -387,7 +387,7 @@ # Skips a token of +token_type+, optionally raising an error. def skip token_type, error = true - type, data, = get + type, = get return unless type # end of stream Index: lib/rdoc/markup/attribute_manager.rb =================================================================== --- lib/rdoc/markup/attribute_manager.rb (revision 29723) +++ lib/rdoc/markup/attribute_manager.rb (revision 29724) @@ -265,7 +265,6 @@ def split_into_flow res = [] current_attr = 0 - str = "" str_len = @str.length Index: lib/rdoc/ruby_lex.rb =================================================================== --- lib/rdoc/ruby_lex.rb (revision 29723) +++ lib/rdoc/ruby_lex.rb (revision 29724) @@ -674,7 +674,7 @@ tk_c = TkLPAREN end @indent_stack.push tk_c - tk = Token(tk_c) + Token(tk_c) end @OP.def_rule("[]", proc{|op, io| @lex_state == EXPR_FNAME}) do Index: lib/rdoc/parser/ruby.rb =================================================================== --- lib/rdoc/parser/ruby.rb (revision 29723) +++ lib/rdoc/parser/ruby.rb (revision 29724) @@ -452,7 +452,8 @@ def parse_attr_accessor(context, single, tk, comment) args = parse_symbol_arg - read = get_tkread + get_tkread + rw = "?" # TODO If nodoc is given, don't document any of them @@ -758,7 +759,8 @@ def parse_meta_attr(context, single, tk, comment) args = parse_symbol_arg - read = get_tkread + get_tkread + rw = "?" # If nodoc is given, don't document any of them Index: lib/rdoc/parser/c.rb =================================================================== --- lib/rdoc/parser/c.rb (revision 29723) +++ lib/rdoc/parser/c.rb (revision 29724) @@ -284,7 +284,6 @@ \s*(\([^)]*\))([^;]|$))"xm comment = $1 body_text = $2 - params = $3 remove_private_comments comment if comment @@ -304,7 +303,6 @@ find_modifiers comment, meth_obj if comment - #meth_obj.params = params meth_obj.start_collecting_tokens tk = RDoc::RubyToken::Token.new nil, 1, 1 tk.set_text body_text -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/