Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Configuration

SuperStruct is a procedural macro, and is configured by superstruct attributes on the type being defined.

  • Struct attributes are applied to the top-level type and configure properties relevant to that, as well as defaults for error types.
  • Field attributes are applied to each struct field and determine the fields of variants, as well as the characteristics of getters and setters.