Exception: ANTLR3::Test::Grammar::CompilationFailure
- Inherits:
-
StandardError
- Object
- StandardError
- ANTLR3::Test::Grammar::CompilationFailure
- Defined in:
- lib/antlr3/test/grammar.rb
Overview
class Grammar::InlineGrammar
Constant Summary collapse
- JAVA_TRACE =
/^(org\.)?antlr\.\S+\(\S+\.java:\d+\)\s*/
Instance Attribute Summary collapse
-
#command ⇒ Object
readonly
Returns the value of attribute command.
-
#grammar ⇒ Object
readonly
Returns the value of attribute grammar.
-
#output ⇒ Object
readonly
Returns the value of attribute output.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(grammar, command, status, output) ⇒ CompilationFailure
constructor
A new instance of CompilationFailure.
Constructor Details
#initialize(grammar, command, status, output) ⇒ CompilationFailure
Returns a new instance of CompilationFailure.
318 319 320 321 322 323 324 325 326 327 328 329 330 331 |
# File 'lib/antlr3/test/grammar.rb', line 318 def initialize( grammar, command, status, output ) @command = command @status = status @output = output.gsub( JAVA_TRACE, '' ) = <<-END.here_indent! % [ command, status, grammar, @output ] | command ``%s'' failed with status %s | %p | ~ ~ ~ command output ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ | %s END super( .chomp! || ) end |
Instance Attribute Details
#command ⇒ Object (readonly)
Returns the value of attribute command.
316 317 318 |
# File 'lib/antlr3/test/grammar.rb', line 316 def command @command end |
#grammar ⇒ Object (readonly)
Returns the value of attribute grammar.
316 317 318 |
# File 'lib/antlr3/test/grammar.rb', line 316 def grammar @grammar end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
316 317 318 |
# File 'lib/antlr3/test/grammar.rb', line 316 def output @output end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
316 317 318 |
# File 'lib/antlr3/test/grammar.rb', line 316 def status @status end |