Skip to main content

token_is_method_call_receiver

Function token_is_method_call_receiver 

Source
fn token_is_method_call_receiver(token: &SyntaxToken) -> bool
Expand description

Returns whether token is the receiver of a method call. Note, being within the receiver of a method call doesn’t count. e.g. if the token is $a, then $a.foo() will return true, while ($a + $b).foo() or x.foo($a) will return false.