lib-ruby-parser (C++ bindings)  4.0.1+ruby-3.1.1
C++ bindings for lib-ruby-parser library
lib_ruby_parser::Const Class Reference

Represents constant access (i.e. Foo::Bar) More...

#include <nodes.hpp>

Public Attributes

Nodescope
 
String name
 Name of the constant, String("Foo") for Foo More...
 
MaybeLoc double_colon_l
 
Loc name_l
 
Loc expression_l
 

Detailed Description

Represents constant access (i.e. Foo::Bar)

Member Data Documentation

◆ double_colon_l

MaybeLoc lib_ruby_parser::Const::double_colon_l

Location of the :: operator. None if constant is taken from the current scope.

A::B
^^

◆ expression_l

Loc lib_ruby_parser::Const::expression_l

Location of the full expression

Foo::Bar
^^^^^^^^

◆ name

String lib_ruby_parser::Const::name

Name of the constant, String("Foo") for Foo

◆ name_l

Loc lib_ruby_parser::Const::name_l

Location of the constant name

Foo::Bar
^^^

◆ scope

Node* lib_ruby_parser::Const::scope

Scope where the constant is taken from:

  1. Some(Const("A")) for A::B
  2. None if it's taken from the current scope (i.e. A)
  3. Some(Cbase) if it's taken from the global scope (i.e. ::A)

The documentation for this class was generated from the following file: