Closed markus-wa closed 5 years ago
It definitely might be helpful if the struct doc is generic enough. In my particular case it was not the case. Usually structure description describes the implementation details, requirements, limitations, etc which is not applicable for the interface type. thus there is an option "-y" to provide a custom interface doc. However, if you think it is needed, you are more than welcome to contribute this change.
Currently only method docs are copied to the interface.
I think it would be beneficial in some cases to have the same doc on the interface type as on the struct.
Specifically I would like that the consumers of my library have the same IDE experience (type docs) when they are working with the interface as they have with the original struct.
example:
ifacemaker -f mytype.go -s MyType --copy-typedoc -i MyInterface