YAML real field type object

A real field type object is the type of floating point number data fields, found in data streams.

Properties

Name Type Description Req? Default

class

String

This property’s value must be real.

Yes if the $inherit property is not set.

$inherit

String

Name of a field type alias from which to inherit.

Yes if the class property is not set.

size

Positive integer

Size of this field type’s instances (bits).

This property’s value must be one of:

32

Single-precision floating point number instances (binary32).

64

Double-precision floating point number instances (binary64).

Yes

alignment

Power-of-two integer

Alignment of the first bit of this field type’s instances within a CTF packet (bits).

No

8

Generated C types

Depending on the value of the size property:

32

float

64

double

Examples

Example 1. Basic single-precision real field type object.
class: real
size: 32
Example 2. Basic double-precision real field type object.
class: real
size: 64
Example 3. 64-bit-aligned single-precision real field type object.
class: real
size: 32
alignment: 64