Expand description
Elixir: keyword Call identity (def, defmodule, quote, …).
Functions§
- elixir_
call_ keyword - Reads the text of the
targetfield of an ElixirCallnode. - elixir_
do_ block_ call_ children - Iterates the direct-child
Callnodes inside thedo_blockof an Elixir Call (typically adefmodule). Used byNpm/Npato scan a module body for method-defining macros /defstructwithout descending into nested modules. Yields no items when the Call has nodo_block. - elixir_
is_ class_ macro - Class-defining macro (
defmodule). Paired withelixir_is_method_macrowhere a caller needs both (“any space-opening declaration”). - elixir_
is_ inside_ quote_ block - Returns true when
nodeis lexically nested inside thedo_blockof aquote do … endCall (Elixir’s metaprogramming template). Adef/defp/defmacro/defmacropinsidequotedoes not define a method of any enclosing module — the syntax tree is a code template emitted later, when the surrounding macro is invoked. Treating those quoted Calls as methods inflatesWmcand disagrees withNpm’s direct-children classification (#310). - elixir_
is_ method_ macro - Method-defining macros (
def,defp,defmacro,defmacrop). The set is duplicated across checker, getter, and several metric impls because each consults it from a different trait surface; centralising the literal here keeps future additions (e.g.defguard) consistent.