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

Attempt to remove runtime match statement for Frames const generic state #1017

Closed
kevinaboos opened this issue Jul 24, 2023 · 1 comment
Closed

Comments

@kevinaboos
Copy link
Member

Not relevant until PR #1004 is merged in.

That was actually my first attempt but Rust doesn't allow for specialized Drop implementations :( (link)

Also, I checked the binary for a simplified version of the Frames tyepstates, and it doesn't seem like the match statement is elided. A generic drop function is called for all Frames objects.

Originally posted by @Ramla-I in #1004 (comment)

@kevinaboos
Copy link
Member Author

Never mind, thanks to @tsoutsman's analysis, this does not result in a runtime operation, as the const param is monomorphized out before runtime.

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

1 participant