Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement Debug for the AST nodes #1665

Closed
angelcaru opened this issue May 19, 2024 · 1 comment
Closed

Implement Debug for the AST nodes #1665

angelcaru opened this issue May 19, 2024 · 1 comment

Comments

@angelcaru
Copy link

When I'm using a Rust library for the first time, my general learning process is usually just spraying dbg!() and todo!() everywhere to get a better feel for the datatypes I'm working with. With Syn, I can't do that because the AST nodes don't implement Debug. Is there a reason behind this? Doesn't seem hard to just add #[derive(Debug)] to every struct defintion.

@Bruflot
Copy link

Bruflot commented May 26, 2024

This is already supported, you just need to enable the extra-traits feature: #583 (comment)

@dtolnay dtolnay closed this as completed Jun 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants