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

Add a attr.rust.no_placeholder attribute to codegen #7440

Closed
wants to merge 1 commit into from

Conversation

abey79
Copy link
Member

@abey79 abey79 commented Sep 18, 2024

What

This attribute sets the placeholder field of the component's reflection to None instead of Some(C::default()). This makes it possible for the component not to implement Default, but make it incompatible with the fallback system (this would trigger the exisiting ComponentFallbackError::MissingPlaceholderValue error).

Checklist

  • I have read and agree to Contributor Guide and the Code of Conduct
  • I've included a screenshot or gif (if applicable)
  • I have tested the web demo (if applicable):
  • The PR title and labels are set such as to maximize their usefulness for the next release's CHANGELOG
  • If applicable, add a new check to the release checklist!
  • If have noted any breaking changes to the log API in CHANGELOG.md and the migration guide

To run all checks from main, comment on the PR with @rerun-bot full-check.

…onent's reflection to not have a placeholder value specified.

This enables the component not to `impl Default`
@Wumpf
Copy link
Member

Wumpf commented Oct 24, 2024

Got #7447 far enough to be sure that that replaces it!

@Wumpf Wumpf closed this Oct 24, 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

Successfully merging this pull request may close these issues.

2 participants