[][src]Struct lib_ruby_parser::nodes::CSend

pub struct CSend {
    pub recv: Node,
    pub method_name: String,
    pub args: Vec<Node>,
    pub dot_l: Range,
    pub selector_l: Range,
    pub begin_l: Option<Range>,
    pub end_l: Option<Range>,
    pub operator_l: Option<Range>,
    pub expression_l: Range,
}

Represents conditional method call using &. operator

Fields

recv: Node

Receiver of the method call, Int("1") for 1&.foo

method_name: String

Name of the method, String("foo") for 1&.foo

args: Vec<Node>

List of arguments

foo&.bar(42)
# and also setters like
foo&.bar = 42
dot_l: Range

Location of the &. operator

foo&.bar
   ~~
selector_l: Range

Location of the method name

foo&.bar(42)
     ~~~
begin_l: Option<Range>

Location of the open parenthesis

foo&.bar(42)
        ~

None if there are no parentheses

end_l: Option<Range>

Location of the closing parenthesis

foo&.bar(42)
           ~

None if there are no parentheses

operator_l: Option<Range>

Location of the operator if CSend is a part of assignment like

foo&.bar = 1
         ~

None for a regular call.

expression_l: Range

Location of the full expression

foo&.bar(42)
~~~~~~~~~~~~

Trait Implementations

impl Clone for CSend[src]

impl Debug for CSend[src]

impl PartialEq<CSend> for CSend[src]

impl StructuralPartialEq for CSend[src]

Auto Trait Implementations

impl RefUnwindSafe for CSend

impl Send for CSend

impl Sync for CSend

impl Unpin for CSend

impl UnwindSafe for CSend

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.