Method: CTypes::Bitfield::Builder#skip
- Defined in:
- lib/ctypes/bitfield/builder.rb
#skip(bits) ⇒ Object
skip bits bits in the layout of this bitfield
111 112 113 114 115 116 117 118 |
# File 'lib/ctypes/bitfield/builder.rb', line 111 def skip(bits) raise Error, "cannot mix `#skip` and `#field` in Bitfield layout" unless @offset @offset += bits @max = @offset if @offset > @max @layout << "skip #{bits}" self end |