[PATCH v10 2/5] rust: support formatting of foreign types