RubyScope

io.joern.rubysrc2cpg.deprecated.astcreation.RubyScope
class RubyScope extends Scope[String, NewIdentifier, NewNode]

Extends the Scope class to help scope variables and create locals.

TODO: Extend this to similarly link parameter nodes (especially this node) for consistency.

Attributes

Graph
Supertypes
class Scope[String, NewIdentifier, NewNode]
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

override def addToScope(identifier: String, variable: NewIdentifier): NewNode

Attributes

Definition Classes
Scope
def createAndLinkLocalNodes(diffGraph: DiffGraphBuilder, paramNames: Set[String]): List[DeclarationNew]

Will generate local nodes for this scope's variables, excluding those that reference parameters.

Will generate local nodes for this scope's variables, excluding those that reference parameters.

Value parameters

paramNames

the names of parameters.

Attributes

override def popScope(): Option[NewNode]

Attributes

Definition Classes
Scope

Inherited methods

def isEmpty: Boolean

Attributes

Inherited from:
Scope
def lookupVariable(identifier: String): Option[V]

Attributes

Inherited from:
Scope
def pushNewScope(scopeNode: NewNode): Unit

Attributes

Inherited from:
Scope
def size: Int

Attributes

Inherited from:
Scope