Fixed odr violation from trying to separate constexpr functions into declaration and definition in separate files. Modified code gen to be in line with current code.

This commit is contained in:
2022-10-24 20:37:40 +11:00
parent 188b462e68
commit 0048df1875
5 changed files with 192 additions and 144 deletions

View File

@@ -0,0 +1,20 @@
enum class RecordType {
AACT, ACHR, ACTI, ADDN, ALCH, AMMO, ANIO, APPA, ARMA, ARMO, ARTO, ASPC,
ASTP, AVIF, BOOK, BPTD, CAMS, CELL, CLAS, CLDC, CLFM, CLMT, COBJ, COLL,
CONT, CPTH, CSTY, DEBR, DIAL, DLBR, DLVW, DOBJ, DOOR, DUAL, ECZN, EFSH,
ENCH, EQUP, EXPL, EYES, FACT, FLOR, FLST, FSTP, FSTS, FURN, GLOB, GMST,
GRAS, GRUP, HAIR, HAZD, HDPT, IDLE, IDLM, IMAD, IMGS, INFO, INGR, IPCT,
IPDS, KEYM, KYWD, LAND, LCRT, LCTN, LENS, LGTM, LIGH, LSCR, LTEX, LVLI,
LVLN, LVSP, MATO, MATT, MESG, MGEF, MISC, MOVT, MSTT, MUSC, MUST, NAVI,
NAVM, NOTE, NPC_, OTFT, PACK, PARW, PBAR, PBEA, PCON, PERK, PFLA, PGRE,
PHZD, PLYR, PMIS, PROJ, PWAT, QUST, RACE, REFR, REGN, RELA, REVB, RFCT,
RGDL, SCEN, SCOL, SCPT, SCRL, SHOU, SLGM, SMBN, SMEN, SMQN, SNCT, SNDR,
SOPM, SOUN, SPEL, SPGD, STAT, TACT, TES4, TREE, TXST, VOLI, VTYP, WATR,
WEAP, WOOP, WRLD, WTHR,
};
[[nodiscard]] std::optional<std::string_view> group_type_to_name(GroupType group_type) noexcept
[[nodiscard]] std::optional<FourCC> record_type_to_fourcc(RecordType record_type) noexcept
[[nodiscard]] std::optional<RecordType> fourcc_to_record_type(FourCC fourcc) noexcept
[[nodiscard]] std::optional<std::string_view> record_type_to_name(RecordType record_type) noexcept
[[nodiscard]] std::optional<std::string_view> flag_to_description(Flag flag) noexcept
[[nodiscard]] std::optional<std::string_view> refr_flag_to_description(RefrFlag refr_flag) noexcept