Navigation
Synopsis Retrieve the value of an Annotation.
Syntax Expr @ Name
Types
Expr Expr @ Name
T <: node Determined by annotation declaration of Name
Description Retrieves the value of annotation Name of the value of Exp (may be undefined!). Also see Replacement for replacing the value of an annotation.
Examples
rascal>anno str node @ color;
ok
rascal>anno str node @ size;
ok
rascal>F = "fn"(123, "abc");
node: "fn"(123,"abc")
rascal>F = F[@color="red"];
node: "fn"(123,"abc")[
  @color="red"
]
rascal>F = F[@size="10"];
node: "fn"(123,"abc")[
  @color="red",
  @size="10"
]
rascal>[email protected];
str: "red"
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.