Class: AdLint::Cc1::InnerVariable

Inherits:
OuterVariable show all
Includes:
Nameable
Defined in:
lib/adlint/cc1/object.rb

Instance Attribute Summary collapse

Attributes included from Nameable

#name

Attributes inherited from OuterVariable

#representative_element

Attributes inherited from ScopedVariable

#scope

Attributes inherited from TypedObject

#type

Attributes inherited from Object

#declarations_and_definitions

Attributes included from Bindable

#binding

Instance Method Summary collapse

Methods inherited from OuterVariable

#assign!, #begin_value_versioning, #end_value_versioning, #enter_value_versioning_group, #inner_variable_at, #inner_variable_named, #leave_value_versioning_group, #rollback_all_value_versions!, #thin_latest_value_version!

Methods inherited from Variable

#assign!, #begin_value_versioning, #end_value_versioning, #enter_value_versioning_group, #function?, #leave_value_versioning_group, #name, #narrow_value_domain!, #outer?, #rollback_all_value_versions!, #thin_latest_value_version!, #uninitialize!, #value, #variable?, #widen_value_domain!

Methods inherited from TypedObject

#to_pointer, #to_pointer_value, #to_value, #to_variable

Methods inherited from Object

#function?, #variable?

Methods included from Bindable

#be_alias_to, #bind_to

Constructor Details

#initialize(mem, outer_var, type, component_name) ⇒ InnerVariable

Returns a new instance of InnerVariable.



569
570
571
572
573
574
# File 'lib/adlint/cc1/object.rb', line 569

def initialize(mem, outer_var, type, component_name)
  @owner = outer_var
  @component_name = component_name
  self.name = create_qualified_name(outer_var, component_name)
  super(mem, nil, type, outer_var.scope)
end

Instance Attribute Details

#component_nameObject (readonly)

Returns the value of attribute component_name.



577
578
579
# File 'lib/adlint/cc1/object.rb', line 577

def component_name
  @component_name
end

#ownerObject (readonly)

Returns the value of attribute owner.



576
577
578
# File 'lib/adlint/cc1/object.rb', line 576

def owner
  @owner
end

Instance Method Details

#declared_as_auto?Boolean

Returns:

  • (Boolean)


591
592
593
# File 'lib/adlint/cc1/object.rb', line 591

def declared_as_auto?
  @owner.declared_as_auto?
end

#declared_as_extern?Boolean

Returns:

  • (Boolean)


583
584
585
# File 'lib/adlint/cc1/object.rb', line 583

def declared_as_extern?
  @owner.declared_as_extern?
end

#declared_as_register?Boolean

Returns:

  • (Boolean)


595
596
597
# File 'lib/adlint/cc1/object.rb', line 595

def declared_as_register?
  @owner.declared_as_register?
end

#declared_as_static?Boolean

Returns:

  • (Boolean)


587
588
589
# File 'lib/adlint/cc1/object.rb', line 587

def declared_as_static?
  @owner.declared_as_static?
end

#designated_by_lvalue?Boolean

Returns:

  • (Boolean)


611
612
613
# File 'lib/adlint/cc1/object.rb', line 611

def designated_by_lvalue?
  true
end

#inner?Boolean

Returns:

  • (Boolean)


607
608
609
# File 'lib/adlint/cc1/object.rb', line 607

def inner?
  true
end

#named?Boolean

Returns:

  • (Boolean)


599
600
601
# File 'lib/adlint/cc1/object.rb', line 599

def named?
  @owner.named?
end

#storage_class_specifiersObject



579
580
581
# File 'lib/adlint/cc1/object.rb', line 579

def storage_class_specifiers
  @owner.storage_class_specifiers
end

#temporary?Boolean

Returns:

  • (Boolean)


603
604
605
# File 'lib/adlint/cc1/object.rb', line 603

def temporary?
  @owner.temporary?
end

#to_named_variableObject



615
616
617
# File 'lib/adlint/cc1/object.rb', line 615

def to_named_variable
  self
end