Class: Pione::Lang::SpecialFeature

Inherits:
FeaturePiece show all
Defined in:
lib/pione/lang/feature-expr.rb

Overview

SpecialFeature is a class for empty feature and boundless feature.

Direct Known Subclasses

AlmightyFeature, EmptyFeature

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from FeaturePiece

feature_type

Methods inherited from Piece

#eval, piece_type_name

Methods included from Util::Positionable

#line_and_column, #pos, #set_source_position

Class Method Details

.symbol(sym = nil) ⇒ Object



25
26
27
# File 'lib/pione/lang/feature-expr.rb', line 25

def symbol(sym=nil)
  sym ? @symbol = sym : sym
end

Instance Method Details

#==(other) ⇒ Object Also known as: eql?



37
38
39
# File 'lib/pione/lang/feature-expr.rb', line 37

def ==(other)
 other.kind_of?(self.class) and symbol == other.symbol
end

#textizeObject



33
34
35
# File 'lib/pione/lang/feature-expr.rb', line 33

def textize
  symbol
end