Allow record extension in types.
Split the alias code into its own file. Add checks for duplicate definitions, bad order of definitions, and type aliases without enough arguments