CodeQL library for Ruby
codeql/ruby-all 0.8.15-dev (changelog, source)
Search

Module Expr

Import path

import codeql.ruby.ast.Expr

Classes

ArgumentList

A sequence of expressions in the right-hand side of an assignment or a return, break or next statement. rb x = 1, *items, 3, *more return 1, 2 next *list break **map return 1, 2, *items, k: 5, **map

BodyStmt

A sequence of statements representing the body of a method, class, module, or do-block. That is, any body that may also include rescue/ensure/else statements.

DestructuredLhsExpr

A “left-hand-side” (LHS) expression of a destructured assignment.

Expr

An expression.

LhsExpr

A “left-hand-side” (LHS) expression. An LhsExpr can occur on the left-hand side of operator assignments (AssignOperation), on the left-hand side of assignments (AssignExpr), as patterns in for loops (ForExpr), and as exception variables in rescue clauses (RescueClause).

Pair

A pair expression. For example, in a hash: rb { foo: bar } Or a keyword argument: rb baz(qux: 1)

ParenthesizedExpr

A parenthesized expression sequence, typically containing a single expression: rb (x + 1) However, they can also contain multiple expressions (the value of the parenthesized expression is the last expression): rb (foo; bar) or even an empty sequence (value is nil): rb ()

RescueClause

A rescue clause. For example:

RescueModifierExpr

An expression with a rescue modifier. For example: rb contents = read_file rescue ""

StmtSequence

A sequence of expressions.

StringConcatenation

A concatenation of string literals.