lib/melbourne/ast/exceptions.rb in melbourne-1.0.0 vs lib/melbourne/ast/exceptions.rb in melbourne-1.0.1
- old
+ new
@@ -14,11 +14,11 @@
# The +rescue+ statement to the +begin+ statement id there is any
#
attr_accessor :rescue
- def initialize(line, body) #:nodoc:
+ def initialize(line, body)
@line = line
@rescue = body
end
end
@@ -43,11 +43,11 @@
# A literal if one is defined as the only statement in the +ensure+ statement
#
attr_accessor :ensure
- def initialize(line, body, ensr) #:nodoc:
+ def initialize(line, body, ensr)
@line = line
@body = body || Nil.new(line)
@ensure = ensr
end
@@ -75,11 +75,11 @@
# The +else+ block of the +rescue+ block (+else+ is an alias for +ensure+ here)
#
attr_accessor :else
- def initialize(line, body, rescue_body, else_body) #:nodoc:
+ def initialize(line, body, rescue_body, else_body)
@line = line
@body = body
@rescue = rescue_body
@else = else_body
end
@@ -98,25 +98,25 @@
# The actual conditions of rescue condition
#
attr_accessor :conditions
- # Assignments in the rescue condition (e.g. <tt>RuntimeError => e</tt>, where +e+ is assigned)
+ # Assignments in the rescue condition (e.g. +RuntimeError => e+, where +e+ is assigned)
#
attr_accessor :assignment
# The body os the +rescue+ block
#
attr_accessor :body
# TODO: document!
- attr_accessor :next #:nodoc:
+ attr_accessor :next
# TODO: document!
- attr_accessor :splat #:nodoc:
+ attr_accessor :splat
- def initialize(line, conditions, body, nxt) #:nodoc:
+ def initialize(line, conditions, body, nxt)
@line = line
@next = nxt
@splat = nil
@assignment = nil
@@ -148,11 +148,11 @@
end
end
end
# TODO: document!
- def assignment?(node) #:nodoc:
+ def assignment?(node)
case node
when VariableAssignment
value = node.value
when AttributeAssignment
value = node.arguments.array.last
@@ -164,10 +164,10 @@
end
end
# TODO: document!
- class RescueSplat < Node #:nodoc:
+ class RescueSplat < Node
attr_accessor :value
def initialize(line, value)
@line = line