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

Expose more methods from mapped guards #444

Open
katietheqt-old opened this issue Jun 12, 2024 · 2 comments
Open

Expose more methods from mapped guards #444

katietheqt-old opened this issue Jun 12, 2024 · 2 comments

Comments

@katietheqt-old
Copy link

katietheqt-old commented Jun 12, 2024

While very useful, mapped guards do not currently expose methods such as raw and force_unlock, which makes using them in certain contexts quite difficult. From what I can tell, there's no soundness reason why they haven't been exposed. Would a PR adding the same APIs to them as the other guards be accepted?

@Amanieu
Copy link
Owner

Amanieu commented Jun 23, 2024

Yes, I would I accept a PR for these. Fundamentally these are unsafe functions so it's fine to expose them with appropriate warnings.

@Earthcomputer
Copy link

I also came across a situation where I needed to downgrade a write mapped guard to a read mapped guard. So there are a few APIs missing.

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

3 participants