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

module: make write_bitcode_to_path accept more general path representations #528

Merged
merged 2 commits into from
Aug 22, 2024

Conversation

airwoodix
Copy link
Contributor

Description

Change the function Module::write_bitcode_to_path to accept a AsRef<Path> argument instead of &Path. This allows passing e.g. string slices instead of explicitly building the Path instance, and matches functions in std::fs.

Since &Path is AsRef<Path>, the change is backwards compatible.

How This Has Been Tested

  • Adapted the example in the docstring
  • The tests checks passing an explicit Path.

Checklist

@TheDan64 TheDan64 merged commit 4028abc into TheDan64:master Aug 22, 2024
18 checks passed
@TheDan64 TheDan64 added this to the 0.6.0 milestone Aug 22, 2024
@airwoodix airwoodix deleted the module-write-asref-path branch August 22, 2024 17:42
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