Class: AdLint::Cc1::DefaultLabeledStatement

Inherits:
LabeledStatement show all
Defined in:
lib/adlint/cc1/syntax.rb

Instance Attribute Summary collapse

Attributes inherited from Statement

#executed

Attributes inherited from SyntaxNode

#head_token, #subsequent_sequence_point, #tail_token

Instance Method Summary collapse

Methods inherited from Statement

#executed?

Methods inherited from SyntaxNode

#head_location, #short_class_name, #tail_location

Methods included from LocationHolder

#analysis_target?

Methods included from Visitable

#accept

Constructor Details

#initialize(stmt) ⇒ DefaultLabeledStatement

Returns a new instance of DefaultLabeledStatement.



3451
3452
3453
3454
# File 'lib/adlint/cc1/syntax.rb', line 3451

def initialize(stmt)
  super()
  @statement = stmt
end

Instance Attribute Details

#normalized_expressionObject

Returns the value of attribute normalized_expression.



3457
3458
3459
# File 'lib/adlint/cc1/syntax.rb', line 3457

def normalized_expression
  @normalized_expression
end

#statementObject (readonly)

Returns the value of attribute statement.



3456
3457
3458
# File 'lib/adlint/cc1/syntax.rb', line 3456

def statement
  @statement
end

Instance Method Details

#inspect(indent = 0) ⇒ Object



3463
3464
3465
# File 'lib/adlint/cc1/syntax.rb', line 3463

def inspect(indent = 0)
  " " * indent + "#{short_class_name}\n" + @statement.inspect(indent + 1)
end

#locationObject



3459
3460
3461
# File 'lib/adlint/cc1/syntax.rb', line 3459

def location
  head_location
end