emk / accessors

(WIP) Getters and setters for Rust using macros 1.1
11 stars 6 forks source link

Doc comments #4

Open Arnavion opened 7 years ago

Arnavion commented 7 years ago
emk commented 7 years ago

I dislike emitting #[allow(missing_docs)] and would prefer a solution that allowed everything to be documented reasonably well.

Arnavion commented 7 years ago

The reason for emitting #[allow(missing_docs)] is for the case where the field has no doc comment and no #[getter(doc)] attribute. I guess you could synthesize something like Gets the `field_name` field of the `StructName`. instead.

Arnavion commented 7 years ago

https://github.com/Arnavion/accessors/commit/befff9ae9de1c5905bbe24eb9d4d4d5111a1a7a5 implements the second and third item, but requires the other commits from #5, so I'll wait for that to be merged first.