All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.joern.x2cpg.datastructures.ScopeElement.scala Maven / Gradle / Ivy

There is a newer version: 4.0.131
Show newest version
package io.joern.x2cpg.datastructures

/** A single element of a scope stack.
  * @tparam I
  *   Identifier type.
  * @tparam V
  *   Variable type.
  * @tparam S
  *   Scope type.
  */
case class ScopeElement[I, V, S](scopeNode: S, variables: Map[I, V] = Map[I, V]()) {
  def addVariable(identifier: I, variable: V): ScopeElement[I, V, S] = {
    ScopeElement(scopeNode, variables + (identifier -> variable))
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy