diff options
| author | Mason Reed <mason@vector35.com> | 2025-05-05 13:17:30 -0400 |
|---|---|---|
| committer | Mason Reed <35282038+emesare@users.noreply.github.com> | 2025-05-12 17:45:24 -0400 |
| commit | 9dadf92c16da5cd21def79ae39ca98803c9208ec (patch) | |
| tree | 3874a659bcb3818f43c1a46ab3ef081b99b47154 /rust/src/download_provider.rs | |
| parent | 9f5491a56f6af1fa9b030f23d40150673a52aaa1 (diff) | |
[Rust] Rename `AsCStr` to `IntoCStr`
Diffstat (limited to 'rust/src/download_provider.rs')
| -rw-r--r-- | rust/src/download_provider.rs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/rust/src/download_provider.rs b/rust/src/download_provider.rs index 7d28058f..e74274f4 100644 --- a/rust/src/download_provider.rs +++ b/rust/src/download_provider.rs @@ -1,6 +1,6 @@ use crate::rc::{Array, CoreArrayProvider, CoreArrayProviderInner, Guard, Ref, RefCountable}; use crate::settings::Settings; -use crate::string::{AsCStr, BnString}; +use crate::string::{BnString, IntoCStr}; use binaryninjacore_sys::*; use std::collections::HashMap; use std::ffi::{c_void, CStr}; @@ -13,7 +13,7 @@ pub struct DownloadProvider { } impl DownloadProvider { - pub fn get<S: AsCStr>(name: S) -> Option<DownloadProvider> { + pub fn get<S: IntoCStr>(name: S) -> Option<DownloadProvider> { let name = name.to_cstr(); let result = unsafe { BNGetDownloadProviderByName(name.as_ptr()) }; if result.is_null() { @@ -131,7 +131,7 @@ impl DownloadInstance { } } - pub fn perform_request<S: AsCStr>( + pub fn perform_request<S: IntoCStr>( &mut self, url: S, callbacks: DownloadInstanceOutputCallbacks, @@ -202,11 +202,11 @@ impl DownloadInstance { } pub fn perform_custom_request< - M: AsCStr, - U: AsCStr, - HK: AsCStr, - HV: AsCStr, - I: IntoIterator<Item = (HK, HV)>, + M: IntoCStr, + U: IntoCStr, + HK: IntoCStr, + HV: IntoCStr, + I: Iterator<Item = (HK, HV)>, >( &mut self, method: M, |
