bsongen: basic types support
bsongen: EncodeInt

Also make some of the types match the encoding.