Class: Epuber::Compiler::Problem::Location
- Inherits:
-
Object
- Object
- Epuber::Compiler::Problem::Location
- Defined in:
- lib/epuber/compiler/problem.rb
Instance Attribute Summary collapse
-
#column ⇒ Object
readonly
Returns the value of attribute column.
-
#length ⇒ Object
readonly
Returns the value of attribute length.
-
#line ⇒ Object
readonly
Returns the value of attribute line.
Instance Method Summary collapse
-
#initialize(line, column, length = nil) ⇒ Location
constructor
A new instance of Location.
Constructor Details
#initialize(line, column, length = nil) ⇒ Location
Returns a new instance of Location.
9 10 11 12 13 |
# File 'lib/epuber/compiler/problem.rb', line 9 def initialize(line, column, length = nil) @line = line @column = column @length = length || 1 end |
Instance Attribute Details
#column ⇒ Object (readonly)
Returns the value of attribute column.
7 8 9 |
# File 'lib/epuber/compiler/problem.rb', line 7 def column @column end |
#length ⇒ Object (readonly)
Returns the value of attribute length.
7 8 9 |
# File 'lib/epuber/compiler/problem.rb', line 7 def length @length end |
#line ⇒ Object (readonly)
Returns the value of attribute line.
7 8 9 |
# File 'lib/epuber/compiler/problem.rb', line 7 def line @line end |