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