Class: YARP::ParseWarning

Inherits:
Object
  • Object
show all
Defined in:
lib/yarp.rb,
ext/yarp/extension.c

Overview

This represents a warning that was encountered during parsing.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, location) ⇒ ParseWarning

Returns a new instance of ParseWarning.



144
145
146
147
# File 'lib/yarp.rb', line 144

def initialize(message, location)
  @message = message
  @location = location
end

Instance Attribute Details

#locationObject (readonly)

Returns the value of attribute location.



142
143
144
# File 'lib/yarp.rb', line 142

def location
  @location
end

#messageObject (readonly)

Returns the value of attribute message.



142
143
144
# File 'lib/yarp.rb', line 142

def message
  @message
end

Instance Method Details

#deconstruct_keys(keys) ⇒ Object



149
150
151
# File 'lib/yarp.rb', line 149

def deconstruct_keys(keys)
  { message: message, location: location }
end