Sun Studio 12 Update 1: Debugging a Program With dbx

assign Command

In native mode, the assign command assigns a new value to a program variable. In Java mode, the assign command assigns a new value to a local variable or parameter.

Native Mode Syntax

assign variable = expression

where:

expression is the value to be assigned to variable.

Java Mode Syntax

assign identifier = expression

where:

class_name is the name of a Java class, using either the package path (using period (.) as a qualifier; for example, test1.extra.T1.Inner) or the full path name (preceded by a pound sign (#) and using slash (/) and dollar sign ($) as qualifiers; for example, #test1/extra/T1$Inner). Enclose class_name in quotation marks if you use the $ qualifier.

expression is a valid Java expression.

field_name is the name of a field in the class.

identifier is a local variable or parameter, including this, the current class instance variable (object_name.field_name) or a class (static) variable (class_name.field_name).

object_name is the name of a Java object.