class AdLint::Assignment

DESCRIPTION

Assignment information.

Public Class Methods

new(loc, var_name, assign_rep) click to toggle source

DESCRIPTION

Constructs the assignment information.

PARAMETER

loc

LocationLocation where the variable appears.

var_name

String – Assigned variable name.

assign_rep

StringAssignment expression representation.

# File lib/adlint/code.rb, line 309
def initialize(loc, var_name, assign_rep)
  @loc        = loc
  @var_name   = var_name
  @assign_rep = assign_rep
end

Private Instance Methods

to_a() click to toggle source

DESCRIPTION

Converts this code structure information into array representation.

RETURN VALUE

Array< Object > – Array representation.

# File lib/adlint/code.rb, line 321
def to_a
  ["ASN", *@loc.to_a, @var_name, @assign_rep]
end