internal static GrapeVariable Create(GrapeSimpleType type, GrapeIdentifier name) { GrapeVariable variable = new GrapeVariable(type, name); variable.InitializeFromTemplate(type); variable.InitializeFromChildren(type.FileName, new GrapeEntity[] {type, name}); return variable; }
public GrapeClass(GrapeList<GrapeModifier> modifiers, GrapeIdentifier identifier, GrapeOptional<GrapeLiteralExpression<int>> size, GrapeOptional<GrapeSimpleType> inherits, GrapeList<GrapeClassItem> classItems) : base(modifiers) { GrapeLiteralExpression<int> sizeLiteral = size; this.size = (sizeLiteral == null) ? default(int?) : sizeLiteral.Value; this.inherits = inherits; this.classItems = classItems.ToList(this).AsReadOnly(); name = identifier.Name; }
public GrapeNameofExpression(GrapeSimpleType value) { this.value = value; }
public GrapeCatchClause(GrapeSimpleType exceptionType, GrapeIdentifier variableIdentifier, GrapeList<GrapeStatement> statements): base(statements) { this.exceptionType = exceptionType; exceptionVariable = GrapeVariable.Create(exceptionType, variableIdentifier); }
public GrapeCatchClause(GrapeSimpleType exceptionType, GrapeList<GrapeStatement> statements): this(exceptionType, null, statements) {}