void Execute_RelativeExpr(out NBase res) { res = null; if (StartOf(6)) { RelativeExpr(out res); } else if (la.kind == 68) { Get(); res = new NRelative(t.val, null, NRelative.NKind.Parameter); } else SynErr(90); }
void Back_RelativeValueExpr(out NBase res) { res = null; if (la.kind == 66) { Get(); } else if (la.kind == 67) { Get(); } else SynErr(88); res = new NRelative(t.val, null, NRelative.NKind.Value); }
void Event_RelativeExpr(out NBase res) { res = null; if (StartOf(6)) { RelativeExpr(out res); } else if (la.kind == 69) { Get(); res = new NRelative(t.val, null, NRelative.NKind.Sender); } else if (la.kind == 70) { Get(); res = new NRelative(t.val, null, NRelative.NKind.Args); } else SynErr(92); }
void RelativeExpr(out NBase res) { res = null; switch (la.kind) { case 42: case 43: { if (la.kind == 42) { Get(); } else { Get(); } res = new NRelative(t.val, null, NRelative.NKind.Context); break; } case 44: case 45: { if (la.kind == 44) { Get(); } else { Get(); } res = new NRelative(t.val, null, NRelative.NKind.Self); break; } case 46: case 47: { if (la.kind == 46) { Get(); } else { Get(); } res = new NRelative(t.val, null, NRelative.NKind.Parent); break; } case 48: case 49: { if (la.kind == 48) { Get(); } else { Get(); } res = new NRelative(t.val, null, NRelative.NKind.Element); Expect(40); Expect(1); ((NRelative)res).ElementName = t.val; Expect(41); break; } case 50: case 51: { if (la.kind == 50) { Get(); } else { Get(); } res = new NRelative(t.val, null, NRelative.NKind.Resource); Expect(40); Expect(1); ((NRelative)res).ResourceName = t.val; Expect(41); break; } case 52: { Get(); res = new NRelative(t.val, null, NRelative.NKind.Reference); Expect(40); Expect(1); ((NRelative)res).ReferenceName = t.val; Expect(41); break; } case 53: case 54: { if (la.kind == 53) { Get(); } else { Get(); } res = new NRelative(t.val, null, NRelative.NKind.Ancestor); NBase type; Expect(40); TypeExpr(out type); ((NRelative)res).AncestorType = (NType)type; if (la.kind == 55) { Get(); Expect(2); ((NRelative)res).AncestorLevel = (int)ParserHelper.ParseInt(t.val); } Expect(41); break; } default: SynErr(84); break; } }