MCPcopy Create free account
hub / github.com/SSheldon/rust-objc / set_ivar

Method set_ivar

src/runtime.rs:517–520  ·  view source on GitHub ↗

Sets the value of the ivar of self with the given name. Panics if self has no ivar with the given name. Unsafe because the caller must ensure that the ivar is actually of type `T`.

(&mut self, name: &str, value: T)

Source from the content-addressed store, hash-verified

515 /// Unsafe because the caller must ensure that the ivar is actually
516 /// of type `T`.
517 pub unsafe fn set_ivar<T>(&mut self, name: &str, value: T)
518 where T: Encode {
519 *self.get_mut_ivar::<T>(name) = value;
520 }
521}
522
523impl fmt::Debug for Object {

Callers 1

test_objectFunction · 0.80

Calls

no outgoing calls

Tested by 1

test_objectFunction · 0.64