Class: FFI::Clang::Types::TypeDef

Inherits:
Type
  • Object
show all
Defined in:
lib/ffi/clang/types/type_def.rb

Instance Attribute Summary

Attributes inherited from Type

#translation_unit, #type

Instance Method Summary collapse

Methods inherited from Type

#==, #alignof, #const_qualified?, create, #declaration, #initialize, #kind, #kind_spelling, #pod?, #ref_qualifier, #restrict_qualified?, #sizeof, #spelling, #to_s, #volatile_qualified?

Constructor Details

This class inherits a constructor from FFI::Clang::Types::Type

Instance Method Details

#anonymous?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'lib/ffi/clang/types/type_def.rb', line 9

def anonymous?
	self.canonical.kind == :type_record && self.canonical.anonymous?
end

#canonicalObject



5
6
7
# File 'lib/ffi/clang/types/type_def.rb', line 5

def canonical
	Type.create Lib.get_canonical_type(@type), @translation_unit
end