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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

add const function to get &str from ArrayString #231

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

DominicBurkart
Copy link

@DominicBurkart DominicBurkart commented Dec 4, 2022

馃憢 Hello @bluss! Thank you for making this crate; it's super useful.

I don't think we can dereference an ArrayString into a &str in a constant function right now, and traits like Deref seem unlikely to become const in the near future. Do you have an idea of the best way to support ArrayString -> string coercion in const functions?

One way would just be to add a new method on ArrayString. I've done that in this PR in case it would be helpful; otherwise, let me know if you prefer me to open an issue for this.

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.

None yet

1 participant