Class: Rubycc::Front::BitfieldInit

Inherits:
Data
  • Object
show all
Defined in:
lib/rubycc/front/initializer_resolver.rb

Overview

A scalar placed into a bit-field. offset identifies the containing storage unit; shift is the field's bit position within that unit. It stays separate from ScalarInit because a bit-field initializer must be a read-modify-write, not a whole-width scalar store at the member's byte.

Instance Attribute Summary collapse

Instance Attribute Details

#offsetObject (readonly)

Returns the value of attribute offset

Returns:

  • (Object)

    the current value of offset



20
21
22
# File 'lib/rubycc/front/initializer_resolver.rb', line 20

def offset
  @offset
end

#shiftObject (readonly)

Returns the value of attribute shift

Returns:

  • (Object)

    the current value of shift



20
21
22
# File 'lib/rubycc/front/initializer_resolver.rb', line 20

def shift
  @shift
end

#typeObject (readonly)

Returns the value of attribute type

Returns:

  • (Object)

    the current value of type



20
21
22
# File 'lib/rubycc/front/initializer_resolver.rb', line 20

def type
  @type
end

#valueObject (readonly)

Returns the value of attribute value

Returns:

  • (Object)

    the current value of value



20
21
22
# File 'lib/rubycc/front/initializer_resolver.rb', line 20

def value
  @value
end

#widthObject (readonly)

Returns the value of attribute width

Returns:

  • (Object)

    the current value of width



20
21
22
# File 'lib/rubycc/front/initializer_resolver.rb', line 20

def width
  @width
end