rust-lang-deprecated / error-chain

Error boilerplate for Rust
Apache License 2.0
730 stars 111 forks source link

not possible to document fields in struct type error in error block. #97

Open andete opened 7 years ago

andete commented 7 years ago

See errors.rs for an example. As far as I can see it is not possible to add documentation to the 3 fields of BridgeError.

It would be nice if that could be made possible in some way.

LFalch commented 7 years ago

@andete The link for the example doesn't work anymore, because the branch is gone.

andete commented 7 years ago

alternative location for errors.rs: https://github.com/Orangenosecom/philipshue/blob/master/src/errors.rs

andete commented 7 years ago

Or rather more permanent: https://github.com/Orangenosecom/philipshue/blob/431d1b166e8a07baac60ea31f6820fb200b0149e/src/errors.rs

Yamakaky commented 7 years ago

^^ Unfortunately, https://github.com/brson/error-chain/issues/63 makes it more complicated that it should. Do you want to try?

andete commented 7 years ago

No, I just noticed the issue wasn't reported yet. Even though it seems to be related to #63 , for a casual user of error-chain this may not be obvious.

Yamakaky commented 7 years ago

Yeah, I myself didn't notice it before your issue ^^