私が望むのは、日付の 3 つのコンポーネントを解析し、それぞれを独自の注釈に格納してから、日付全体を表す複雑な構造を作成することです。以下を試してみましたが、うまくいきませんでした。
DECLARE Annotation CommDate (Annotation CMonth, Annotation CDate, Annotation CYear);
DECLARE Annotation CommenceMonth;
DECLARE Annotation CommenceYear;
DECLARE Annotation CommenceDate;
NUM{REGEXP("[0-3]?[0-9]?") -> MARK(CommenceMonth)};
CommenceMonth SPECIAL NUM{REGEXP("[0-3]?[0-9]?") -> MARK(CommenceDate)};
CommenceDate SPECIAL NUM{REGEXP("19..|20..") -> MARK(CommenceYear)};
CommenceMonth CommenceDate CommenceYear {-> CREATE(CommDate, 1,2,3, "CMonth" = 1, "CDate" = 2, "CYear" = 3) };
「12/31/2014」のようなものをフィードすると、3 つの CommenceXXX 注釈に値が割り当てられますが、複雑な構造の CommDate には値が割り当てられません。