Browse files

Change @yield YARD tag for `Pry::Code#select`

It yields `LOC` now. Oh, and also prettify some default method
arguments.

Signed-off-by: Kyrylo Silin <kyrylosilin@gmail.com>
  • Loading branch information...
1 parent 97f3d76 commit cb4b114be05f2f34c96aa42fcc12a1fd0fe1f826 @kyrylo kyrylo committed Jan 5, 2013
Showing with 6 additions and 6 deletions.
  1. +6 −6 lib/pry/code.rb
View
12 lib/pry/code.rb
@@ -237,7 +237,7 @@ def push(line, lineno = nil)
# Filter the lines using the given block.
#
- # @yield [line]
+ # @yield [LOC]
# @return [Code]
def select(&blk)
alter do
@@ -252,7 +252,7 @@ def select(&blk)
# @param [Range, Integer] start_line
# @param [Integer?] end_line
# @return [Code]
- def between(start_line, end_line=nil)
+ def between(start_line, end_line = nil)
return self unless start_line
start_line, end_line = reform_start_and_end_lines(start_line, end_line)
@@ -338,7 +338,7 @@ def grep(pattern)
#
# @param [Boolean?] y_n
# @return [Code]
- def with_line_numbers(y_n=true)
+ def with_line_numbers(y_n = true)
alter do
@with_line_numbers = y_n
end
@@ -361,7 +361,7 @@ def with_marker(lineno = 1)
#
# @param [Integer?] spaces
# @return [Code]
- def with_indentation(spaces=0)
+ def with_indentation(spaces = 0)
alter do
@with_indentation = !!spaces
@indentation_num = spaces
@@ -400,7 +400,7 @@ def comment_describing(line_number)
#
# @param [Integer] line_number (1-based)
# @return [String] the code.
- def expression_at(line_number, consume=0)
+ def expression_at(line_number, consume = 0)
self.class.expression_at(raw, line_number, :consume => consume)
end
@@ -409,7 +409,7 @@ def expression_at(line_number, consume=0)
# @param [Integer] line_number line number starting from 1
# @param [Module] top_module the module in which this code exists
# @return [Array<Module>] a list of open modules.
- def nesting_at(line_number, top_module=Object)
+ def nesting_at(line_number, top_module = Object)
Pry::Indent.nesting_at(raw, line_number)
end

0 comments on commit cb4b114

Please sign in to comment.