Navigation
Synopsis Assign to a field of a tuple, relation or datatype.
Syntax Assignable . Name = Exp
Description The value V of Assignable is determined and should be of a type that has a field Name. The value of that field is replaced in V by the value of Exp resulting in a new value V' that is assigned to Assignable.
Examples
rascal>data FREQ = wf(str word, int freq);
ok
rascal>W = wf("rascal", 1000);
FREQ: wf("rascal",1000)
rascal>W.freq = 100000;
FREQ: wf("rascal",100000)
Is this page unclear, or have you spotted an error? Please add a comment below and help us to improve it. For all other questions and remarks, visit ask.rascal-mpl.org.