class AdLint::Cc1::FunctionType

Attributes

parameter_types[R]
return_type[R]

Public Class Methods

new(type_tbl, ret_type, param_types, have_va_list = false) click to toggle source
Calls superclass method AdLint::Cc1::Type::new
# File lib/adlint/cc1/type.rb, line 2421
def initialize(type_tbl, ret_type, param_types, have_va_list = false)
  super(type_tbl, create_name(ret_type, param_types, have_va_list))
  @return_type = ret_type
  @parameter_types = param_types
  @have_va_list = have_va_list
end

Public Instance Methods

==(rhs_type) click to toggle source
# File lib/adlint/cc1/type.rb, line 2936
def ==(rhs_type)
  case rhs_type
  when FunctionType
    if parameter_types.empty? || rhs_type.parameter_types.empty?
      return_type == rhs_type.return_type
    else
      return_type == rhs_type.return_type &&
        parameter_types == rhs_type.parameter_types &&
        have_va_list? == rhs_type.have_va_list?
    end
  else
    false
  end
end
_arithmetic_type_with_array(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2906
def _arithmetic_type_with_array(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  lhs_type # NOTREACHED
end
_arithmetic_type_with_bitfield(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2886
def _arithmetic_type_with_bitfield(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with BitfieldType and FunctionType
  #       makes integer-promoted type of BitfieldType.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_char(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2688
def _arithmetic_type_with_char(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `char' and FunctionType
  #       makes integer-promoted type of `char'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_double(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2873
def _arithmetic_type_with_double(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `double' and FunctionType makes `double'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_enum(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2893
def _arithmetic_type_with_enum(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with EnumType and FunctionType makes EnumType.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_extended_big_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2921
def _arithmetic_type_with_extended_big_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with ExtendedBigIntType and FunctionType
  #       makes ExtendedBigIntType.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_float(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2867
def _arithmetic_type_with_float(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `float' and FunctionType makes `float'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_function(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2683
def _arithmetic_type_with_function(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  lhs_type # NOTREACHED
end
_arithmetic_type_with_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2751
def _arithmetic_type_with_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `int' and FunctionType makes `int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_long(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2784
def _arithmetic_type_with_long(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `long' and FunctionType makes `long'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_long_double(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2879
def _arithmetic_type_with_long_double(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `long double' and FunctionType
  #       makes `long double'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_long_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2804
def _arithmetic_type_with_long_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `long int' and FunctionType
  #       makes `long int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_long_long(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2825
def _arithmetic_type_with_long_long(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `long long' and FunctionType
  #       makes `long long'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_long_long_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2846
def _arithmetic_type_with_long_long_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `long long int' and FunctionType
  #       makes `long long int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_pointer(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2899
def _arithmetic_type_with_pointer(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with PointerType and FunctionType
  #       makes PointerType.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_short(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2709
def _arithmetic_type_with_short(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `short' and FunctionType
  #       makes integer-promoted type of `short'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_short_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2730
def _arithmetic_type_with_short_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `short int' and FunctionType
  #       makes integer-promoted type of `short int'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_signed(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2757
def _arithmetic_type_with_signed(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed' and FunctionType makes `signed'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_signed_char(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2695
def _arithmetic_type_with_signed_char(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed char' and FunctionType
  #       makes integer-promoted type of `signed char'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_signed_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2763
def _arithmetic_type_with_signed_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed int' and FunctionType
  #       makes `signed int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_signed_long(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2790
def _arithmetic_type_with_signed_long(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed long' and FunctionType
  #       makes `signed long'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_signed_long_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2811
def _arithmetic_type_with_signed_long_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed long int' and FunctionType
  #       makes `signed long int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_signed_long_long(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2832
def _arithmetic_type_with_signed_long_long(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed long long' and FunctionType
  #       makes `signed long long'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_signed_long_long_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2853
def _arithmetic_type_with_signed_long_long_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed long long int' and FunctionType
  #       makes `signed long long int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_signed_short(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2716
def _arithmetic_type_with_signed_short(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed short' and FunctionType
  #       makes integer-promoted type of `signed short'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_signed_short_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2737
def _arithmetic_type_with_signed_short_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `signed short int' and FunctionType
  #       makes integer-promoted type of `signed short int'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_struct(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2911
def _arithmetic_type_with_struct(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  lhs_type # NOTREACHED
end
_arithmetic_type_with_undeclared(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2671
def _arithmetic_type_with_undeclared(lhs_type, rhs_type = self)
  rhs_type.arithmetic_type_with(lhs_type)
end
_arithmetic_type_with_union(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2916
def _arithmetic_type_with_union(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  lhs_type # NOTREACHED
end
_arithmetic_type_with_unresolved(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2675
def _arithmetic_type_with_unresolved(lhs_type, rhs_type = self)
  rhs_type.arithmetic_type_with(lhs_type)
end
_arithmetic_type_with_unsigned(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2770
def _arithmetic_type_with_unsigned(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned' and FunctionType
  #       makes `unsigned'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_unsigned_char(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2702
def _arithmetic_type_with_unsigned_char(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned char' and FunctionType
  #       makes integer-promoted type of `unsigned char'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_unsigned_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2777
def _arithmetic_type_with_unsigned_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned int' and FunctionType
  #       makes `unsigned int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_unsigned_long(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2797
def _arithmetic_type_with_unsigned_long(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned long' and FunctionType
  #       makes `unsigned long'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_unsigned_long_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2818
def _arithmetic_type_with_unsigned_long_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned long int' and FunctionType
  #       makes `unsigned long int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_unsigned_long_long(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2839
def _arithmetic_type_with_unsigned_long_long(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned long long' and FunctionType
  #       makes `unsigned long long'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_unsigned_long_long_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2860
def _arithmetic_type_with_unsigned_long_long_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned long long int' and FunctionType
  #       makes `unsigned long long int'.
  lhs_type # NOTREACHED
end
_arithmetic_type_with_unsigned_short(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2723
def _arithmetic_type_with_unsigned_short(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned short' and FunctionType
  #       makes integer-promoted type of `unsigned short'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_unsigned_short_int(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2744
def _arithmetic_type_with_unsigned_short_int(lhs_type, rhs_type = self)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  # NOTE: Binary operation with `unsigned short int' and FunctionType
  #       makes integer-promoted type of `unsigned short int'.
  lhs_type.integer_promoted_type # NOTREACHED
end
_arithmetic_type_with_void(lhs_type, rhs_type = self) click to toggle source
# File lib/adlint/cc1/type.rb, line 2679
def _arithmetic_type_with_void(lhs_type, rhs_type = self)
  rhs_type.arithmetic_type_with(lhs_type)
end
arbitrary_value() click to toggle source
# File lib/adlint/cc1/type.rb, line 2626
def arbitrary_value
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
argument_promoted_type() click to toggle source
# File lib/adlint/cc1/type.rb, line 2662
def argument_promoted_type
  self # NOTREACHED
end
arithmetic_type_with(type) click to toggle source
# File lib/adlint/cc1/type.rb, line 2666
def arithmetic_type_with(type)
  # NOTE: An arithmetic operation with FunctionType must not be executed!
  type._arithmetic_type_with_function(self)
end
array?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2513
def array?
  false
end
base_type() click to toggle source
# File lib/adlint/cc1/type.rb, line 2471
def base_type
  nil
end
bit_alignment() click to toggle source
# File lib/adlint/cc1/type.rb, line 2461
def bit_alignment
  0
end
bit_size() click to toggle source
# File lib/adlint/cc1/type.rb, line 2457
def bit_size
  0
end
bitfield?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2574
def bitfield?
  false
end
brief_image() click to toggle source
# File lib/adlint/cc1/type.rb, line 2444
def brief_image
  @brief_image ||=
    create_brief_image(@return_type, @parameter_types, @have_va_list)
end
coerce_array_value(val) click to toggle source
# File lib/adlint/cc1/type.rb, line 2646
def coerce_array_value(val)
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
coerce_composite_value(val) click to toggle source
# File lib/adlint/cc1/type.rb, line 2650
def coerce_composite_value(val)
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
coerce_scalar_value(val) click to toggle source
# File lib/adlint/cc1/type.rb, line 2642
def coerce_scalar_value(val)
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
coercible?(to_type) click to toggle source
# File lib/adlint/cc1/type.rb, line 2497
def coercible?(to_type)
  false
end
compatible?(to_type) click to toggle source
# File lib/adlint/cc1/type.rb, line 2485
def compatible?(to_type)
  return false unless to_type.function?

  lhs_params = @parameter_types
  rhs_params = to_type.parameter_types

  @return_type.compatible?(to_type.return_type) &&
    lhs_params.size == rhs_params.size &&
    lhs_params.zip(rhs_params).all? { |lhs, rhs| lhs.compatible?(rhs) } &&
    @have_va_list == to_type.have_va_list?
end
const?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2562
def const?
  false
end
corresponding_signed_type() click to toggle source
# File lib/adlint/cc1/type.rb, line 2928
def corresponding_signed_type
  self # NOTREACHED
end
corresponding_unsigned_type() click to toggle source
# File lib/adlint/cc1/type.rb, line 2932
def corresponding_unsigned_type
  self # NOTREACHED
end
declarations() click to toggle source
# File lib/adlint/cc1/type.rb, line 2431
def declarations
  @return_type.declarations +
    @parameter_types.reduce([]) { |dcls, type| dcls + type.declarations }
end
dup() click to toggle source
# File lib/adlint/cc1/type.rb, line 2951
def dup
  FunctionType.new(type_table, @return_type.dup,
                   @parameter_types.map { |t| t.dup }, @have_va_list)
end
enum?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2537
def enum?
  false
end
enumerators() click to toggle source
# File lib/adlint/cc1/type.rb, line 2590
def enumerators
  []
end
explicitly_signed?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2582
def explicitly_signed?
  false
end
floating?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2509
def floating?
  false
end
function?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2533
def function?
  true
end
have_va_list?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2586
def have_va_list?
  @have_va_list
end
id() click to toggle source
# File lib/adlint/cc1/type.rb, line 2436
def id
  @id ||= FunctionTypeId.new(@return_type, @parameter_types, @have_va_list)
end
image() click to toggle source
# File lib/adlint/cc1/type.rb, line 2440
def image
  @image ||= create_image(@return_type, @parameter_types, @have_va_list)
end
impl_length() click to toggle source
# File lib/adlint/cc1/type.rb, line 2598
def impl_length
  0
end
incomplete?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2479
def incomplete?
  @return_type.incomplete? && !@return_type.void? or
    @parameter_types.empty? ||
      @parameter_types.any? { |type| type.incomplete? && !type.void? }
end
integer?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2505
def integer?
  false
end
integer_conversion_rank() click to toggle source
# File lib/adlint/cc1/type.rb, line 2654
def integer_conversion_rank
  0 # NOTREACHED
end
integer_promoted_type() click to toggle source
# File lib/adlint/cc1/type.rb, line 2658
def integer_promoted_type
  self # NOTREACHED
end
length() click to toggle source
# File lib/adlint/cc1/type.rb, line 2594
def length
  0
end
location() click to toggle source
# File lib/adlint/cc1/type.rb, line 2449
def location
  nil
end
max() click to toggle source
# File lib/adlint/cc1/type.rb, line 2614
def max
  0
end
member_named(name) click to toggle source
# File lib/adlint/cc1/type.rb, line 2606
def member_named(name)
  nil
end
members() click to toggle source
# File lib/adlint/cc1/type.rb, line 2602
def members
  []
end
min() click to toggle source
# File lib/adlint/cc1/type.rb, line 2610
def min
  0
end
named?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2453
def named?
  true
end
nil_value() click to toggle source
# File lib/adlint/cc1/type.rb, line 2618
def nil_value
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
parameter_value() click to toggle source
# File lib/adlint/cc1/type.rb, line 2634
def parameter_value
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
pointer?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2525
def pointer?
  false
end
qualified?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2529
def qualified?
  false
end
real_type() click to toggle source
# File lib/adlint/cc1/type.rb, line 2465
def real_type
  type_table.function_type(@return_type.real_type,
                           @parameter_types.map { |type| type.real_type },
                           @have_va_list)
end
restrict?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2570
def restrict?
  false
end
return_value() click to toggle source
# File lib/adlint/cc1/type.rb, line 2638
def return_value
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
scalar?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2501
def scalar?
  false
end
signed?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2578
def signed?
  false
end
standard?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2549
def standard?
  false
end
struct?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2517
def struct?
  false
end
undeclared?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2553
def undeclared?
  false
end
undefined_value() click to toggle source
# File lib/adlint/cc1/type.rb, line 2630
def undefined_value
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end
union?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2521
def union?
  false
end
unqualify() click to toggle source
# File lib/adlint/cc1/type.rb, line 2475
def unqualify
  self
end
unresolved?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2557
def unresolved?
  @return_type.unresolved? ||
    @parameter_types.any? { |type| type.unresolved? }
end
user?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2541
def user?
  false
end
void?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2545
def void?
  false
end
volatile?() click to toggle source
# File lib/adlint/cc1/type.rb, line 2566
def volatile?
  false
end
zero_value() click to toggle source
# File lib/adlint/cc1/type.rb, line 2622
def zero_value
  ScalarValue.of_nil(logical_right_shift?) # NOTREACHED
end

Private Instance Methods

create_brief_image(ret_type, param_types, have_va_list) click to toggle source
# File lib/adlint/cc1/type.rb, line 2969
def create_brief_image(ret_type, param_types, have_va_list)
  "#{ret_type.brief_image}(" +
    param_types.map { |type| type.brief_image }.join(", ") +
    (have_va_list ? ",...)" : ")")
end
create_image(ret_type, param_types, have_va_list) click to toggle source
# File lib/adlint/cc1/type.rb, line 2963
def create_image(ret_type, param_types, have_va_list)
  "#{ret_type.image}(" +
    param_types.map { |type| type.image }.join(", ") +
    (have_va_list ? ",...)" : ")")
end
create_name(ret_type, param_types, have_va_list) click to toggle source
# File lib/adlint/cc1/type.rb, line 2957
def create_name(ret_type, param_types, have_va_list)
  "#{ret_type.name}(" +
    param_types.map { |type| type.name }.join(", ") +
    (have_va_list ? ",...)" : ")")
end