Skip to content

Better with attribute#548

Draft
fredszaq wants to merge 6 commits into
JelteF:masterfrom
fredszaq:better-with-attribute
Draft

Better with attribute#548
fredszaq wants to merge 6 commits into
JelteF:masterfrom
fredszaq:better-with-attribute

Conversation

@fredszaq
Copy link
Copy Markdown
Contributor

@fredszaq fredszaq commented May 11, 2026

Requires #535, (I will mark this PR as non-draft once #535 is merged; for now, you will see changes from both PRs in the diff). The actual changes are in this commit d24745a.

Synopsis

Allow with atribute to contain syn::ExprCall and syn::ExprClosure in addition to syn::Path

Solution

This uses the same approach as what was done for the #[from_str(error(...))]. I extracted the type used to parse the content of the attribute to one named Callable.

Checklist

  • Documentation is updated (if required)
  • Tests are added/updated (if required)
  • CHANGELOG entry is added (if required)

@fredszaq fredszaq force-pushed the better-with-attribute branch from 694af23 to d24745a Compare May 11, 2026 15:18
@fredszaq fredszaq mentioned this pull request May 11, 2026
3 tasks
@fredszaq fredszaq force-pushed the better-with-attribute branch from d24745a to 603d92d Compare May 18, 2026 13:35
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

Successfully merging this pull request may close these issues.

1 participant