コード例 #1
0
ファイル: Parser.cs プロジェクト: Altaxo/Altaxo
	void SimpleNonInvocationExpression(
//#line  1723 "VBNET.ATG" 
out Expression pexpr) {

//#line  1725 "VBNET.ATG" 
		Expression expr;
		CollectionInitializerExpression cie;
		TypeReference type = null;
		string name = String.Empty;
		Location startLocation = la.Location;
		pexpr = null;
		
		if (StartOf(34)) {
			switch (la.kind) {
			case 3: {
				lexer.NextToken();

//#line  1735 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 4: {
				lexer.NextToken();

//#line  1736 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 7: {
				lexer.NextToken();

//#line  1737 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 6: {
				lexer.NextToken();

//#line  1738 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 5: {
				lexer.NextToken();

//#line  1739 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 9: {
				lexer.NextToken();

//#line  1740 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 8: {
				lexer.NextToken();

//#line  1741 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 217: {
				lexer.NextToken();

//#line  1743 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(true, "true");  
				break;
			}
			case 122: {
				lexer.NextToken();

//#line  1744 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(false, "false"); 
				break;
			}
			case 165: {
				lexer.NextToken();

//#line  1745 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(null, "null");  
				break;
			}
			case 37: {
				lexer.NextToken();
				Expr(
//#line  1746 "VBNET.ATG" 
out expr);
				Expect(38);

//#line  1746 "VBNET.ATG" 
				pexpr = new ParenthesizedExpression(expr); 
				break;
			}
			case 2: case 58: case 62: case 64: case 65: case 66: case 67: case 70: case 87: case 98: case 104: case 107: case 116: case 121: case 126: case 133: case 139: case 143: case 146: case 147: case 170: case 176: case 178: case 184: case 203: case 212: case 213: case 223: case 224: case 230: {
				Identifier();

//#line  1748 "VBNET.ATG" 
				pexpr = new IdentifierExpression(t.val);
				pexpr.StartLocation = t.Location; pexpr.EndLocation = t.EndLocation;
				
				if (
//#line  1751 "VBNET.ATG" 
la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
					lexer.NextToken();
					Expect(169);
					TypeArgumentList(
//#line  1752 "VBNET.ATG" 
((IdentifierExpression)pexpr).TypeArguments);
					Expect(38);
				}
				break;
			}
			case 68: case 71: case 82: case 99: case 100: case 109: case 141: case 151: case 168: case 196: case 201: case 202: case 208: case 221: case 222: case 225: {

//#line  1754 "VBNET.ATG" 
				string val = String.Empty; 
				if (StartOf(12)) {
					PrimitiveTypeName(
//#line  1755 "VBNET.ATG" 
out val);
				} else if (la.kind == 168) {
					lexer.NextToken();

//#line  1755 "VBNET.ATG" 
					val = "System.Object"; 
				} else SynErr(280);

//#line  1756 "VBNET.ATG" 
				pexpr = new TypeReferenceExpression(new TypeReference(val, true)); 
				break;
			}
			case 153: {
				lexer.NextToken();

//#line  1757 "VBNET.ATG" 
				pexpr = new ThisReferenceExpression(); 
				break;
			}
			case 158: case 159: {

//#line  1758 "VBNET.ATG" 
				Expression retExpr = null; 
				if (la.kind == 158) {
					lexer.NextToken();

//#line  1759 "VBNET.ATG" 
					retExpr = new BaseReferenceExpression() { StartLocation = t.Location, EndLocation = t.EndLocation }; 
				} else if (la.kind == 159) {
					lexer.NextToken();

//#line  1760 "VBNET.ATG" 
					retExpr = new ClassReferenceExpression() { StartLocation = t.Location, EndLocation = t.EndLocation }; 
				} else SynErr(281);
				Expect(26);
				IdentifierOrKeyword(
//#line  1762 "VBNET.ATG" 
out name);

//#line  1762 "VBNET.ATG" 
				pexpr = new MemberReferenceExpression(retExpr, name) { StartLocation = startLocation, EndLocation = t.EndLocation }; 
				break;
			}
			case 130: {
				lexer.NextToken();
				Expect(26);
				Identifier();

//#line  1764 "VBNET.ATG" 
				type = new TypeReference(t.val ?? ""); 

//#line  1766 "VBNET.ATG" 
				type.IsGlobal = true; 

//#line  1767 "VBNET.ATG" 
				pexpr = new TypeReferenceExpression(type); 
				break;
			}
			case 162: {
				ObjectCreateExpression(
//#line  1768 "VBNET.ATG" 
out expr);

//#line  1768 "VBNET.ATG" 
				pexpr = expr; 
				break;
			}
			case 35: {
				CollectionInitializer(
//#line  1769 "VBNET.ATG" 
out cie);

//#line  1769 "VBNET.ATG" 
				pexpr = cie; 
				break;
			}
			case 94: case 106: case 219: {

//#line  1771 "VBNET.ATG" 
				CastType castType = CastType.Cast; 
				if (la.kind == 106) {
					lexer.NextToken();
				} else if (la.kind == 94) {
					lexer.NextToken();

//#line  1773 "VBNET.ATG" 
					castType = CastType.Conversion; 
				} else if (la.kind == 219) {
					lexer.NextToken();

//#line  1774 "VBNET.ATG" 
					castType = CastType.TryCast; 
				} else SynErr(282);
				Expect(37);
				Expr(
//#line  1776 "VBNET.ATG" 
out expr);
				Expect(22);
				TypeName(
//#line  1776 "VBNET.ATG" 
out type);
				Expect(38);

//#line  1777 "VBNET.ATG" 
				pexpr = new CastExpression(type, expr, castType); 
				break;
			}
			case 76: case 77: case 78: case 79: case 80: case 81: case 83: case 85: case 86: case 90: case 91: case 92: case 93: case 95: case 96: case 97: {
				CastTarget(
//#line  1778 "VBNET.ATG" 
out type);
				Expect(37);
				Expr(
//#line  1778 "VBNET.ATG" 
out expr);
				Expect(38);

//#line  1778 "VBNET.ATG" 
				pexpr = new CastExpression(type, expr, CastType.PrimitiveConversion); 
				break;
			}
			case 57: {
				lexer.NextToken();
				Expr(
//#line  1779 "VBNET.ATG" 
out expr);

//#line  1779 "VBNET.ATG" 
				pexpr = new AddressOfExpression(expr); 
				break;
			}
			case 129: {
				lexer.NextToken();
				Expect(37);
				GetTypeTypeName(
//#line  1780 "VBNET.ATG" 
out type);
				Expect(38);

//#line  1780 "VBNET.ATG" 
				pexpr = new TypeOfExpression(type); 
				break;
			}
			case 220: {
				lexer.NextToken();
				SimpleExpr(
//#line  1781 "VBNET.ATG" 
out expr);
				Expect(144);
				TypeName(
//#line  1781 "VBNET.ATG" 
out type);

//#line  1781 "VBNET.ATG" 
				pexpr = new TypeOfIsExpression(expr, type); 
				break;
			}
			case 135: {
				ConditionalExpression(
//#line  1782 "VBNET.ATG" 
out pexpr);
				break;
			}
			case 10: case 16: case 17: case 18: case 19: {
				XmlLiteralExpression(
//#line  1783 "VBNET.ATG" 
out pexpr);
				break;
			}
			}
		} else if (StartOf(35)) {
			if (la.kind == 26) {
				lexer.NextToken();
				if (la.kind == 10) {
					lexer.NextToken();
					IdentifierOrKeyword(
//#line  1789 "VBNET.ATG" 
out name);
					Expect(11);

//#line  1790 "VBNET.ATG" 
					pexpr = new XmlMemberAccessExpression(null, XmlAxisType.Element, name, true) { StartLocation = startLocation, EndLocation = t.EndLocation }; 
				} else if (StartOf(33)) {
					IdentifierOrKeyword(
//#line  1791 "VBNET.ATG" 
out name);

//#line  1792 "VBNET.ATG" 
					pexpr = new MemberReferenceExpression(null, name) { StartLocation = startLocation, EndLocation = t.EndLocation }; 
				} else SynErr(283);
			} else if (la.kind == 29) {
				lexer.NextToken();
				IdentifierOrKeyword(
//#line  1794 "VBNET.ATG" 
out name);

//#line  1794 "VBNET.ATG" 
				pexpr = new BinaryOperatorExpression(null, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name) { StartLocation = t.Location, EndLocation = t.EndLocation }); 
			} else {

//#line  1795 "VBNET.ATG" 
				XmlAxisType axisType = XmlAxisType.Element; bool isXmlIdentifier = false; 
				if (la.kind == 27) {
					lexer.NextToken();

//#line  1796 "VBNET.ATG" 
					axisType = XmlAxisType.Descendents; 
				} else if (la.kind == 28) {
					lexer.NextToken();

//#line  1796 "VBNET.ATG" 
					axisType = XmlAxisType.Attribute; 
				} else SynErr(284);
				if (la.kind == 10) {
					lexer.NextToken();

//#line  1797 "VBNET.ATG" 
					isXmlIdentifier = true; 
				}
				IdentifierOrKeyword(
//#line  1797 "VBNET.ATG" 
out name);
				if (la.kind == 11) {
					lexer.NextToken();
				}

//#line  1798 "VBNET.ATG" 
				pexpr = new XmlMemberAccessExpression(null, axisType, name, isXmlIdentifier); 
			}
		} else SynErr(285);

//#line  1803 "VBNET.ATG" 
		if (pexpr != null) {
		pexpr.StartLocation = startLocation;
		pexpr.EndLocation = t.EndLocation;
		}
		
	}
コード例 #2
0
		public virtual object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data) {
			throw new global::System.NotImplementedException("XmlMemberAccessExpression");
		}
コード例 #3
0
ファイル: Parser.cs プロジェクト: Altaxo/Altaxo
	void SimpleExpr(
//#line  1693 "VBNET.ATG" 
out Expression pexpr) {

//#line  1694 "VBNET.ATG" 
		string name; Location startLocation = la.Location; 
		SimpleNonInvocationExpression(
//#line  1697 "VBNET.ATG" 
out pexpr);
		while (StartOf(32)) {
			if (la.kind == 26) {
				lexer.NextToken();
				if (la.kind == 10) {
					lexer.NextToken();
					IdentifierOrKeyword(
//#line  1700 "VBNET.ATG" 
out name);
					Expect(11);

//#line  1701 "VBNET.ATG" 
					pexpr = new XmlMemberAccessExpression(pexpr, XmlAxisType.Element, name, true); 
				} else if (StartOf(33)) {
					IdentifierOrKeyword(
//#line  1702 "VBNET.ATG" 
out name);

//#line  1703 "VBNET.ATG" 
					pexpr = new MemberReferenceExpression(pexpr, name) { StartLocation = startLocation, EndLocation = t.EndLocation }; 
				} else SynErr(278);
				if (
//#line  1705 "VBNET.ATG" 
la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
					lexer.NextToken();
					Expect(169);
					TypeArgumentList(
//#line  1706 "VBNET.ATG" 
((MemberReferenceExpression)pexpr).TypeArguments);
					Expect(38);
				}
			} else if (la.kind == 29) {
				lexer.NextToken();
				IdentifierOrKeyword(
//#line  1708 "VBNET.ATG" 
out name);

//#line  1708 "VBNET.ATG" 
				pexpr = new BinaryOperatorExpression(pexpr, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name) { StartLocation = t.Location, EndLocation = t.EndLocation }); 
			} else if (la.kind == 27 || la.kind == 28) {

//#line  1709 "VBNET.ATG" 
				XmlAxisType type = XmlAxisType.Attribute; bool isXmlName = false; 
				if (la.kind == 28) {
					lexer.NextToken();
				} else if (la.kind == 27) {
					lexer.NextToken();

//#line  1710 "VBNET.ATG" 
					type = XmlAxisType.Descendents; 
				} else SynErr(279);
				if (la.kind == 10) {
					lexer.NextToken();

//#line  1710 "VBNET.ATG" 
					isXmlName = true; 
				}
				IdentifierOrKeyword(
//#line  1710 "VBNET.ATG" 
out name);
				if (la.kind == 11) {
					lexer.NextToken();
				}

//#line  1711 "VBNET.ATG" 
				pexpr = new XmlMemberAccessExpression(pexpr, type, name, isXmlName); 
			} else {
				InvocationExpression(
//#line  1712 "VBNET.ATG" 
ref pexpr);
			}
		}

//#line  1716 "VBNET.ATG" 
		if (pexpr != null) {
		pexpr.StartLocation = startLocation;
		pexpr.EndLocation = t.EndLocation;
		}
		
	}
コード例 #4
0
ファイル: ResolveVisitor.cs プロジェクト: Altaxo/Altaxo
		public override object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data)
		{
			switch (xmlMemberAccessExpression.AxisType) {
				case XmlAxisType.Element:
				case XmlAxisType.Descendents:
					return CreateResolveResult(
						new TypeReference("System.Collections.Generic.IEnumerable",
						                  new List<TypeReference> { new TypeReference("System.Xml.Linq.XElement") { IsGlobal = true } }
						                 ) { IsGlobal = true }
					);
				case XmlAxisType.Attribute:
					return CreateResolveResult(new TypeReference("System.String", true) { IsGlobal = true });
				default:
					throw new Exception("Invalid value for XmlAxisType");
			}
		}
コード例 #5
0
ファイル: Parser.cs プロジェクト: BooMWax/SharpDevelop
	void SimpleNonInvocationExpression(
#line  1730 "VBNET.ATG" 
out Expression pexpr) {

#line  1732 "VBNET.ATG" 
		Expression expr;
		CollectionInitializerExpression cie;
		TypeReference type = null;
		string name = String.Empty;
		Location startLocation = la.Location;
		pexpr = null;
		
		if (StartOf(35)) {
			switch (la.kind) {
			case 3: {
				lexer.NextToken();

#line  1742 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 4: {
				lexer.NextToken();

#line  1743 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 7: {
				lexer.NextToken();

#line  1744 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 6: {
				lexer.NextToken();

#line  1745 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 5: {
				lexer.NextToken();

#line  1746 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 9: {
				lexer.NextToken();

#line  1747 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 8: {
				lexer.NextToken();

#line  1748 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };  
				break;
			}
			case 220: {
				lexer.NextToken();

#line  1750 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(true, "true");  
				break;
			}
			case 124: {
				lexer.NextToken();

#line  1751 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(false, "false"); 
				break;
			}
			case 168: {
				lexer.NextToken();

#line  1752 "VBNET.ATG" 
				pexpr = new PrimitiveExpression(null, "null");  
				break;
			}
			case 37: {
				lexer.NextToken();
				Expr(
#line  1753 "VBNET.ATG" 
out expr);
				Expect(38);

#line  1753 "VBNET.ATG" 
				pexpr = new ParenthesizedExpression(expr); 
				break;
			}
			case 2: case 58: case 62: case 64: case 65: case 66: case 67: case 68: case 69: case 72: case 89: case 100: case 106: case 109: case 118: case 123: case 128: case 135: case 141: case 145: case 148: case 149: case 150: case 173: case 179: case 181: case 187: case 206: case 215: case 216: case 226: case 227: case 233: case 240: {
				Identifier();

#line  1755 "VBNET.ATG" 
				pexpr = new IdentifierExpression(t.val);
				pexpr.StartLocation = t.Location; pexpr.EndLocation = t.EndLocation;
				
				if (
#line  1758 "VBNET.ATG" 
la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
					lexer.NextToken();
					Expect(172);
					TypeArgumentList(
#line  1759 "VBNET.ATG" 
((IdentifierExpression)pexpr).TypeArguments);
					Expect(38);
				}
				break;
			}
			case 70: case 73: case 84: case 101: case 102: case 111: case 143: case 154: case 171: case 199: case 204: case 205: case 211: case 224: case 225: case 228: {

#line  1761 "VBNET.ATG" 
				string val = String.Empty; 
				if (StartOf(12)) {
					PrimitiveTypeName(
#line  1762 "VBNET.ATG" 
out val);
				} else if (la.kind == 171) {
					lexer.NextToken();

#line  1762 "VBNET.ATG" 
					val = "System.Object"; 
				} else SynErr(284);

#line  1763 "VBNET.ATG" 
				pexpr = new TypeReferenceExpression(new TypeReference(val, true)); 
				break;
			}
			case 156: {
				lexer.NextToken();

#line  1764 "VBNET.ATG" 
				pexpr = new ThisReferenceExpression(); 
				break;
			}
			case 161: case 162: {

#line  1765 "VBNET.ATG" 
				Expression retExpr = null; 
				if (la.kind == 161) {
					lexer.NextToken();

#line  1766 "VBNET.ATG" 
					retExpr = new BaseReferenceExpression() { StartLocation = t.Location, EndLocation = t.EndLocation }; 
				} else if (la.kind == 162) {
					lexer.NextToken();

#line  1767 "VBNET.ATG" 
					retExpr = new ClassReferenceExpression() { StartLocation = t.Location, EndLocation = t.EndLocation }; 
				} else SynErr(285);
				Expect(26);
				IdentifierOrKeyword(
#line  1769 "VBNET.ATG" 
out name);

#line  1769 "VBNET.ATG" 
				pexpr = new MemberReferenceExpression(retExpr, name) { StartLocation = startLocation, EndLocation = t.EndLocation }; 
				break;
			}
			case 132: {
				lexer.NextToken();
				Expect(26);
				Identifier();

#line  1771 "VBNET.ATG" 
				type = new TypeReference(t.val ?? ""); 

#line  1773 "VBNET.ATG" 
				type.IsGlobal = true; 

#line  1774 "VBNET.ATG" 
				pexpr = new TypeReferenceExpression(type); 
				break;
			}
			case 165: {
				ObjectCreateExpression(
#line  1775 "VBNET.ATG" 
out expr);

#line  1775 "VBNET.ATG" 
				pexpr = expr; 
				break;
			}
			case 35: {
				CollectionInitializer(
#line  1776 "VBNET.ATG" 
out cie);

#line  1776 "VBNET.ATG" 
				pexpr = cie; 
				break;
			}
			case 96: case 108: case 222: {

#line  1778 "VBNET.ATG" 
				CastType castType = CastType.Cast; 
				if (la.kind == 108) {
					lexer.NextToken();
				} else if (la.kind == 96) {
					lexer.NextToken();

#line  1780 "VBNET.ATG" 
					castType = CastType.Conversion; 
				} else if (la.kind == 222) {
					lexer.NextToken();

#line  1781 "VBNET.ATG" 
					castType = CastType.TryCast; 
				} else SynErr(286);
				Expect(37);
				Expr(
#line  1783 "VBNET.ATG" 
out expr);
				Expect(22);
				TypeName(
#line  1783 "VBNET.ATG" 
out type);
				Expect(38);

#line  1784 "VBNET.ATG" 
				pexpr = new CastExpression(type, expr, castType); 
				break;
			}
			case 78: case 79: case 80: case 81: case 82: case 83: case 85: case 87: case 88: case 92: case 93: case 94: case 95: case 97: case 98: case 99: {
				CastTarget(
#line  1785 "VBNET.ATG" 
out type);
				Expect(37);
				Expr(
#line  1785 "VBNET.ATG" 
out expr);
				Expect(38);

#line  1785 "VBNET.ATG" 
				pexpr = new CastExpression(type, expr, CastType.PrimitiveConversion); 
				break;
			}
			case 57: {
				lexer.NextToken();
				Expr(
#line  1786 "VBNET.ATG" 
out expr);

#line  1786 "VBNET.ATG" 
				pexpr = new AddressOfExpression(expr); 
				break;
			}
			case 131: {
				lexer.NextToken();
				Expect(37);
				GetTypeTypeName(
#line  1787 "VBNET.ATG" 
out type);
				Expect(38);

#line  1787 "VBNET.ATG" 
				pexpr = new TypeOfExpression(type); 
				break;
			}
			case 223: {
				lexer.NextToken();
				SimpleExpr(
#line  1788 "VBNET.ATG" 
out expr);
				Expect(146);
				TypeName(
#line  1788 "VBNET.ATG" 
out type);

#line  1788 "VBNET.ATG" 
				pexpr = new TypeOfIsExpression(expr, type); 
				break;
			}
			case 137: {
				ConditionalExpression(
#line  1789 "VBNET.ATG" 
out pexpr);
				break;
			}
			case 10: case 16: case 17: case 18: case 19: {
				XmlLiteralExpression(
#line  1790 "VBNET.ATG" 
out pexpr);
				break;
			}
			}
		} else if (StartOf(36)) {
			if (la.kind == 26) {
				lexer.NextToken();
				if (la.kind == 10) {
					lexer.NextToken();
					IdentifierOrKeyword(
#line  1796 "VBNET.ATG" 
out name);
					Expect(11);

#line  1797 "VBNET.ATG" 
					pexpr = new XmlMemberAccessExpression(null, XmlAxisType.Element, name, true) { StartLocation = startLocation, EndLocation = t.EndLocation }; 
				} else if (StartOf(34)) {
					IdentifierOrKeyword(
#line  1798 "VBNET.ATG" 
out name);

#line  1799 "VBNET.ATG" 
					pexpr = new MemberReferenceExpression(null, name) { StartLocation = startLocation, EndLocation = t.EndLocation }; 
				} else SynErr(287);
			} else if (la.kind == 29) {
				lexer.NextToken();
				IdentifierOrKeyword(
#line  1801 "VBNET.ATG" 
out name);

#line  1801 "VBNET.ATG" 
				pexpr = new BinaryOperatorExpression(null, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name) { StartLocation = t.Location, EndLocation = t.EndLocation }); 
			} else {

#line  1802 "VBNET.ATG" 
				XmlAxisType axisType = XmlAxisType.Element; bool isXmlIdentifier = false; 
				if (la.kind == 27) {
					lexer.NextToken();

#line  1803 "VBNET.ATG" 
					axisType = XmlAxisType.Descendents; 
				} else if (la.kind == 28) {
					lexer.NextToken();

#line  1803 "VBNET.ATG" 
					axisType = XmlAxisType.Attribute; 
				} else SynErr(288);
				if (la.kind == 10) {
					lexer.NextToken();

#line  1804 "VBNET.ATG" 
					isXmlIdentifier = true; 
				}
				IdentifierOrKeyword(
#line  1804 "VBNET.ATG" 
out name);
				if (la.kind == 11) {
					lexer.NextToken();
				}

#line  1805 "VBNET.ATG" 
				pexpr = new XmlMemberAccessExpression(null, axisType, name, isXmlIdentifier); 
			}
		} else SynErr(289);

#line  1810 "VBNET.ATG" 
		if (pexpr != null) {
		pexpr.StartLocation = startLocation;
		pexpr.EndLocation = t.EndLocation;
		}
		
	}
コード例 #6
0
		public virtual object TrackedVisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data) {
			return base.VisitXmlMemberAccessExpression(xmlMemberAccessExpression, data);
		}
コード例 #7
0
		public sealed override object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data) {
			this.BeginVisit(xmlMemberAccessExpression);
			object result = this.TrackedVisitXmlMemberAccessExpression(xmlMemberAccessExpression, data);
			this.EndVisit(xmlMemberAccessExpression);
			return result;
		}
コード例 #8
0
			public override object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data)
			{
				if (xmlMemberAccessExpression.TargetObject.IsNull) {
					IdentifierExpression id = new IdentifierExpression(withAccessor);
					xmlMemberAccessExpression.TargetObject = id;
					id.Parent = xmlMemberAccessExpression;
				}
				
				return base.VisitXmlMemberAccessExpression(xmlMemberAccessExpression, data);
			}
コード例 #9
0
		public object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data)
		{
			throw new NotImplementedException();
		}
コード例 #10
0
		public virtual object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data) {
			Debug.Assert((xmlMemberAccessExpression != null));
			Debug.Assert((xmlMemberAccessExpression.TargetObject != null));
			nodeStack.Push(xmlMemberAccessExpression.TargetObject);
			xmlMemberAccessExpression.TargetObject.AcceptVisitor(this, data);
			xmlMemberAccessExpression.TargetObject = ((Expression)(nodeStack.Pop()));
			return null;
		}
コード例 #11
0
		public virtual object VisitXmlMemberAccessExpression(XmlMemberAccessExpression xmlMemberAccessExpression, object data) {
			Debug.Assert((xmlMemberAccessExpression != null));
			Debug.Assert((xmlMemberAccessExpression.TargetObject != null));
			return xmlMemberAccessExpression.TargetObject.AcceptVisitor(this, data);
		}
コード例 #12
0
ファイル: Parser.cs プロジェクト: Bombadil77/SharpDevelop
	void SimpleExpr(
#line  1670 "VBNET.ATG" 
out Expression pexpr) {

#line  1671 "VBNET.ATG" 
		string name; 
		SimpleNonInvocationExpression(
#line  1673 "VBNET.ATG" 
out pexpr);
		while (StartOf(31)) {
			if (la.kind == 26) {
				lexer.NextToken();
				if (la.kind == 10) {
					lexer.NextToken();
					IdentifierOrKeyword(
#line  1676 "VBNET.ATG" 
out name);
					Expect(11);

#line  1677 "VBNET.ATG" 
					pexpr = new XmlMemberAccessExpression(pexpr, XmlAxisType.Element, name, true); 
				} else if (StartOf(32)) {
					IdentifierOrKeyword(
#line  1678 "VBNET.ATG" 
out name);

#line  1679 "VBNET.ATG" 
					pexpr = new MemberReferenceExpression(pexpr, name); 
				} else SynErr(278);
				if (
#line  1681 "VBNET.ATG" 
la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
					lexer.NextToken();
					Expect(169);
					TypeArgumentList(
#line  1682 "VBNET.ATG" 
((MemberReferenceExpression)pexpr).TypeArguments);
					Expect(38);
				}
			} else if (la.kind == 29) {
				lexer.NextToken();
				IdentifierOrKeyword(
#line  1684 "VBNET.ATG" 
out name);

#line  1684 "VBNET.ATG" 
				pexpr = new BinaryOperatorExpression(pexpr, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name)); 
			} else if (la.kind == 27 || la.kind == 28) {

#line  1685 "VBNET.ATG" 
				XmlAxisType type = XmlAxisType.Attribute; bool isXmlName = false; 
				if (la.kind == 28) {
					lexer.NextToken();
				} else if (la.kind == 27) {
					lexer.NextToken();

#line  1686 "VBNET.ATG" 
					type = XmlAxisType.Descendents; 
				} else SynErr(279);
				if (la.kind == 10) {
					lexer.NextToken();

#line  1686 "VBNET.ATG" 
					isXmlName = true; 
				}
				IdentifierOrKeyword(
#line  1686 "VBNET.ATG" 
out name);
				if (la.kind == 11) {
					lexer.NextToken();
				}

#line  1687 "VBNET.ATG" 
				pexpr = new XmlMemberAccessExpression(pexpr, type, name, isXmlName); 
			} else {
				InvocationExpression(
#line  1688 "VBNET.ATG" 
ref pexpr);
			}
		}
	}