class AdLint::Cc1::StructType

Attributes

image[RW]
location[RW]

Public Class Methods

new(type_tbl, type_dcl, membs) click to toggle source
Calls superclass method AdLint::Cc1::CompositeDataType::new
# File lib/adlint/cc1/type.rb, line 6714
def initialize(type_tbl, type_dcl, membs)
  super(type_tbl, type_dcl.identifier.value, [type_dcl], membs)
  @image = type_dcl.struct_specifier.to_s
  @location = type_dcl.location
end

Public Instance Methods

arithmetic_type_with(type) click to toggle source
# File lib/adlint/cc1/type.rb, line 6743
def arithmetic_type_with(type)
  type._arithmetic_type_with_struct(self)
end
brief_image() click to toggle source
# File lib/adlint/cc1/type.rb, line 6727
def brief_image
  "struct #{name}"
end
id() click to toggle source
# File lib/adlint/cc1/type.rb, line 6723
def id
  @id ||= StructTypeId.new(name)
end
named?() click to toggle source
# File lib/adlint/cc1/type.rb, line 6731
def named?
  declarations.all? { |dcl| !dcl.struct_specifier.anonymous? }
end
struct?() click to toggle source
# File lib/adlint/cc1/type.rb, line 6735
def struct?
  true
end
union?() click to toggle source
# File lib/adlint/cc1/type.rb, line 6739
def union?
  false
end