[][src]Macro objc::msg_send

macro_rules! msg_send {
    (super($obj:expr, $superclass:expr), $name:ident) => { ... };
    (super($obj:expr, $superclass:expr), $($name:ident : $arg:expr)+) => { ... };
    ($obj:expr, $name:ident) => { ... };
    ($obj:expr, $($name:ident : $arg:expr)+) => { ... };
}

Sends a message to an object.

The first argument can be any type that dereferences to a type that implements Message, like a reference, pointer, or an Id. The syntax is similar to the message syntax in Objective-C. Variadic arguments are not currently supported.

Example

let obj: *mut Object;
let description: *const Object = msg_send![obj, description];
let _: () = msg_send![obj, setArg1:1 arg2:2];