Split out the struct-building interface.
Tighten the union type representation.

Use an option instead of a bool.
Merge pull request #63 from yallop/split-out-structs

Split out the struct building interface