Convert class to struct

August 1, 2018 ยท View on GitHub

{{< Concepts >}}

Convert class to struct

Constraints

  • All members are simple public members.

Recipe

1. Update all forward declarations

Find all usages of the type. Replace the word 'class' with 'struct' wherever it occurs.

1. Update primary declaration

2. Remove the public keyword

It is now the default and all members are public anyway.

3. Compile.

Contents

  1. 11. Update all forward declarations
  2. 21. Update primary declaration
  3. 32. Remove the public keyword
  4. 43. Compile.