writing types, fixes #3

updated according to AS email 22/08