Sha256: 0e50a7c5c9c467888031e0e9e42fadf282a7a126971a92f522fbd03acd76b2d9

Contents?: true

Size: 499 Bytes

Versions: 13

Compression:

Stored size: 499 Bytes

Contents

module Antlr4::Runtime

  class EmptyPredictionContext < SingletonPredictionContext
    def initialize(return_state)
      super(nil, return_state)
    end

    EMPTY = EmptyPredictionContext.new(PredictionContextUtils::EMPTY_RETURN_STATE)

    def isEmpty
      true
    end

    def size
      1
    end

    def parent(_index=nil)
      nil
    end

    def return_state(_index=nil)
      @return_state
    end

    def equals(o)
      self == o
    end

    def to_s
      '$'
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
antlr4-runtime-0.2.12 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.11 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.10 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.9 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.8 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.7 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.6 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.5 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.4 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.3 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.2 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.1 lib/antlr4/runtime/empty_prediction_context.rb
antlr4-runtime-0.2.0 lib/antlr4/runtime/empty_prediction_context.rb