Handle nil pointers. Add very limited support for recursive types, to make field type specs themselves encodable. Could be generalized but I have no use case