From 9dadf92c16da5cd21def79ae39ca98803c9208ec Mon Sep 17 00:00:00 2001 From: Mason Reed Date: Mon, 5 May 2025 13:17:30 -0400 Subject: [Rust] Rename `AsCStr` to `IntoCStr` --- rust/src/collaboration/group.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'rust/src/collaboration/group.rs') diff --git a/rust/src/collaboration/group.rs b/rust/src/collaboration/group.rs index b8b32c7a..08efa079 100644 --- a/rust/src/collaboration/group.rs +++ b/rust/src/collaboration/group.rs @@ -1,6 +1,6 @@ use super::Remote; use crate::rc::{Array, CoreArrayProvider, CoreArrayProviderInner, Guard, Ref, RefCountable}; -use crate::string::{AsCStr, BnString}; +use crate::string::{BnString, IntoCStr}; use binaryninjacore_sys::*; use std::fmt; use std::fmt::{Display, Formatter}; @@ -49,7 +49,7 @@ impl RemoteGroup { /// Set group name /// You will need to push the group to update the Remote. - pub fn set_name(&self, name: U) { + pub fn set_name(&self, name: U) { let name = name.to_cstr(); unsafe { BNCollaborationGroupSetName(self.handle.as_ptr(), name.as_ptr()) } } @@ -84,7 +84,7 @@ impl RemoteGroup { pub fn set_users(&self, usernames: I) -> Result<(), ()> where I: IntoIterator, - I::Item: AsCStr, + I::Item: IntoCStr, { let usernames: Vec<_> = usernames.into_iter().map(|u| u.to_cstr()).collect(); let mut usernames_raw: Vec<_> = usernames.iter().map(|s| s.as_ptr()).collect(); @@ -102,7 +102,7 @@ impl RemoteGroup { } /// Test if a group has a user with the given username - pub fn contains_user(&self, username: U) -> bool { + pub fn contains_user(&self, username: U) -> bool { let username = username.to_cstr(); unsafe { BNCollaborationGroupContainsUser(self.handle.as_ptr(), username.as_ptr()) } } -- cgit v1.3.1