Skip to main content

simple_symbol

Function simple_symbol 

Source
pub fn simple_symbol(
    node: &Node<'_>,
    content: &str,
    name: &str,
    kind: SymbolKind,
    docstring: Option<String>,
) -> Symbol
Expand description

Create a simple symbol with standard defaults.

Used by languages with straightforward function/method syntax where symbols:

  • Have public visibility
  • Use first line as signature
  • Have no attributes or children
  • Don’t implement interfaces

Languages using this: cmake, glsl, graphql, hlsl, awk, elm, fish, haskell, jq, julia, ocaml, powershell, zsh