elichai / log-derive

A procedural macro for auto logging output of functions
https://docs.rs/log-derive
Apache License 2.0
189 stars 12 forks source link

Suggestion: The default fmt string should include the name of the function rather than "LOG DERIVE" #10

Closed TedDriggs closed 5 years ago

TedDriggs commented 5 years ago

The current default format string is good advertising for the crate, but more or less requires that I change it, and then I'm repeating the name of the function twice, once for the fn declaration, and once in the format string. Having the default format string be the function name instead would make it more useful by default in my opinion.

elichai commented 5 years ago

Yes. That wasn't to advertise the crate, It was to help me distinguish the logs that came from the macro from other logs, but now that I published it I need to change it. I'll do something like fn foo() => {:?}

elichai commented 5 years ago

Done. https://github.com/elichai/log-derive/commit/3728d2ea5a1fff880d92e74491758872c7f54717