IO/unicode: added missing #include "./arithmetic.hpp".
EndianUtils: made Endian an enum-class; snake_cased members.
Made variable enums enum-classes, renamed members.

detail/vartype:
	renamed VariableType to VarType, snake_cased members;¹
	merged VariableMasks and VariableClass, snake_cased members;
	added var_mask() and var_type_is_of();
	get_vartype_name(): lookup with a switch instead of ffs() and an array.

Template:
	created Field struct to take over LayoutFieldFlag and separate properties;
	added Flags enum and property;
	added permit_empty flag to replace the layout field "empty" flag;
	changed type_mask property type to VarMask.

ScriptParser: added in_scope(VarType) variant, moved implementations to header.

doc: tidy.

1: Two renames: VARTYPE_FLOAT became VarType::floatp, and VARTYPE_BOOL
became VarType::floatp.
ScriptWriter: moved Flags enum into class, snake_cased members; added state store.
StateStore: made test() match *states* exactly;¹ added test_any().

1: All existing usage in duct++ (and komiga projects) have assumed
this implicitly because it was only advertised as taking one state.
Now both test functions accept state combinations and explicitly
specify how they match against the state store value.
ScriptParser: moved states into State enum-class with StateStore.