Пример #1
0
	void FormalParameter(
//#line  2948 "VBNET.ATG" 
out ParameterDeclarationExpression p) {

//#line  2950 "VBNET.ATG" 
		AttributeSection section;
		List<AttributeSection> attributes = new List<AttributeSection>();
		TypeReference type = null;
		ParamModifierList mod = new ParamModifierList(this);
		Expression expr = null;
		p = null;
		ArrayList arrayModifiers = null;
		Location startLocation = la.Location;
		
		while (la.kind == 40) {
			AttributeSection(
//#line  2960 "VBNET.ATG" 
out section);

//#line  2960 "VBNET.ATG" 
			attributes.Add(section); 
		}
		while (StartOf(29)) {
			ParameterModifier(
//#line  2961 "VBNET.ATG" 
mod);
		}
		Identifier();

//#line  2962 "VBNET.ATG" 
		string parameterName = t.val; 
		if (
//#line  2963 "VBNET.ATG" 
IsDims()) {
			ArrayTypeModifiers(
//#line  2963 "VBNET.ATG" 
out arrayModifiers);
		}
		if (la.kind == 63) {
			lexer.NextToken();
			TypeName(
//#line  2964 "VBNET.ATG" 
out type);
		}

//#line  2966 "VBNET.ATG" 
		if(type != null) {
		if (arrayModifiers != null) {
			if (type.RankSpecifier != null) {
				Error("array rank only allowed one time");
			} else {
				type.RankSpecifier = (int[])arrayModifiers.ToArray(typeof(int));
			}
		}
		}
		
		if (la.kind == 20) {
			lexer.NextToken();
			Expr(
//#line  2976 "VBNET.ATG" 
out expr);
		}

//#line  2978 "VBNET.ATG" 
		mod.Check();
		p = new ParameterDeclarationExpression(type, parameterName, mod.Modifier, expr);
		p.Attributes = attributes;
		p.StartLocation = startLocation;
		p.EndLocation = t.EndLocation;
		
	}
Пример #2
0
	void FormalParameter(
#line  2189 "VBNET.ATG" 
out ParameterDeclarationExpression p) {

#line  2191 "VBNET.ATG" 
		TypeReference type = null;
		ParamModifierList mod = new ParamModifierList(this);
		Expression expr = null;
		p = null;ArrayList arrayModifiers = null;
		
		while (StartOf(33)) {
			ParameterModifier(
#line  2196 "VBNET.ATG" 
mod);
		}
		Identifier();

#line  2197 "VBNET.ATG" 
		string parameterName = t.val; 
		if (
#line  2198 "VBNET.ATG" 
IsDims()) {
			ArrayTypeModifiers(
#line  2198 "VBNET.ATG" 
out arrayModifiers);
		}
		if (la.kind == 48) {
			lexer.NextToken();
			TypeName(
#line  2199 "VBNET.ATG" 
out type);
		}

#line  2201 "VBNET.ATG" 
		if(type != null) {
		if (arrayModifiers != null) {
			if (type.RankSpecifier != null) {
				Error("array rank only allowed one time");
			} else {
				type.RankSpecifier = (int[])arrayModifiers.ToArray(typeof(int));
			}
		}
		} else {
			type = new TypeReference("System.Object", arrayModifiers == null ? null : (int[])arrayModifiers.ToArray(typeof(int)));
		}
		
		if (la.kind == 11) {
			lexer.NextToken();
			Expr(
#line  2213 "VBNET.ATG" 
out expr);
		}

#line  2215 "VBNET.ATG" 
		mod.Check();
		p = new ParameterDeclarationExpression(type, parameterName, mod.Modifier, expr);
		
	}
Пример #3
0
	void FormalParameter(
#line  2642 "VBNET.ATG" 
out ParameterDeclarationExpression p) {

#line  2644 "VBNET.ATG" 
		AttributeSection section;
		List<AttributeSection> attributes = new List<AttributeSection>();
		TypeReference type = null;
		ParamModifierList mod = new ParamModifierList(this);
		Expression expr = null;
		p = null;
		ArrayList arrayModifiers = null;
		
		while (la.kind == 28) {
			AttributeSection(
#line  2653 "VBNET.ATG" 
out section);

#line  2653 "VBNET.ATG" 
			attributes.Add(section); 
		}
		while (StartOf(35)) {
			ParameterModifier(
#line  2654 "VBNET.ATG" 
mod);
		}
		Identifier();

#line  2655 "VBNET.ATG" 
		string parameterName = t.val; 
		if (
#line  2656 "VBNET.ATG" 
IsDims()) {
			ArrayTypeModifiers(
#line  2656 "VBNET.ATG" 
out arrayModifiers);
		}
		if (la.kind == 50) {
			lexer.NextToken();
			TypeName(
#line  2657 "VBNET.ATG" 
out type);
		}

#line  2659 "VBNET.ATG" 
		if(type != null) {
		if (arrayModifiers != null) {
			if (type.RankSpecifier != null) {
				Error("array rank only allowed one time");
			} else {
				type.RankSpecifier = (int[])arrayModifiers.ToArray(typeof(int));
			}
		}
		} else {
			type = new TypeReference("System.Object", arrayModifiers == null ? null : (int[])arrayModifiers.ToArray(typeof(int)));
		}
		
		if (la.kind == 10) {
			lexer.NextToken();
			Expr(
#line  2671 "VBNET.ATG" 
out expr);
		}

#line  2673 "VBNET.ATG" 
		mod.Check();
		p = new ParameterDeclarationExpression(type, parameterName, mod.Modifier, expr);
		p.Attributes = attributes;
		
	}
Пример #4
0
	void FormalParameter(
#line  2883 "VBNET.ATG" 
out ParameterDeclarationExpression p) {

#line  2885 "VBNET.ATG" 
		AttributeSection section;
		List<AttributeSection> attributes = new List<AttributeSection>();
		TypeReference type = null;
		ParamModifierList mod = new ParamModifierList(this);
		Expression expr = null;
		p = null;
		ArrayList arrayModifiers = null;
		
		while (la.kind == 40) {
			AttributeSection(
#line  2894 "VBNET.ATG" 
out section);

#line  2894 "VBNET.ATG" 
			attributes.Add(section); 
		}
		while (StartOf(48)) {
			ParameterModifier(
#line  2895 "VBNET.ATG" 
mod);
		}
		Identifier();

#line  2896 "VBNET.ATG" 
		string parameterName = t.val; 
		if (
#line  2897 "VBNET.ATG" 
IsDims()) {
			ArrayTypeModifiers(
#line  2897 "VBNET.ATG" 
out arrayModifiers);
		}
		if (la.kind == 63) {
			lexer.NextToken();
			TypeName(
#line  2898 "VBNET.ATG" 
out type);
		}

#line  2900 "VBNET.ATG" 
		if(type != null) {
		if (arrayModifiers != null) {
			if (type.RankSpecifier != null) {
				Error("array rank only allowed one time");
			} else {
				type.RankSpecifier = (int[])arrayModifiers.ToArray(typeof(int));
			}
		}
		}
		
		if (la.kind == 20) {
			lexer.NextToken();
			Expr(
#line  2910 "VBNET.ATG" 
out expr);
		}

#line  2912 "VBNET.ATG" 
		mod.Check();
		p = new ParameterDeclarationExpression(type, parameterName, mod.Modifier, expr);
		p.Attributes = attributes;
		
	}