rusty
rusty copied to clipboard
feat: derive try_from trait impl for inner AstStatement structs, add convenience macro
Adds the derive_more crate to derive a TryFrom implementation for most of the AstStatement variants. This should allow for more concise and convenient pattern matching when trying to extract information from the innter AstStatement-structs.
I've started replacing existing code with the macro where I thought it was sensible/would improve readibility. There are most likely many instances I've missed, but that shouldn't be the focus of this PR. These instances can be changed as they are encountered.