reworked to support additional constant tests, encode support started for structure types
move enums out of modules.jl
first stab at simple structs
add support for encoding struct, datarrays, and undef values.  Structs still need a bit of work