Another use case for __traits(docComment)

FeepingCreature feepingcreature at
Mon Nov 11 11:33:43 UTC 2019

On Friday, 8 November 2019 at 14:00:03 UTC, Adam D. Ruppe wrote:
> Writing code to wrap some Phobos functions for a script 
> language and need documentation to be displayed at runtime...
> Would be really nice to just say if(other_docs.length == 0) 
> return __traits(docComment, item).
> A UDA can populate other_docs in some functions, but when 
> wrapping libraries you can't add that. Having the doc comment 
> available through reflection means we can reuse these existing 
> items.

Yes, please!!

More information about the Digitalmars-d mailing list