X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=mcs%2Fmcs%2FChangeLog;h=13911a4314231d56146f9e964b5d2029333d35ad;hb=8d510ba7f34bbe25a5c6df1046b15bf94ead6acb;hp=008fc47b5f45f54ea8add0b5aede174d8afb0ec1;hpb=791ce25fc7d6ca999ebd4415efa6822a96f1183f;p=mono.git diff --git a/mcs/mcs/ChangeLog b/mcs/mcs/ChangeLog index 008fc47b5f4..13911a43142 100755 --- a/mcs/mcs/ChangeLog +++ b/mcs/mcs/ChangeLog @@ -1,3 +1,630 @@ +2001-11-18 Ravi Pratap + + * expression.cs (ArrayCreation::ValidateInitializers): Update to perform + some type checking etc. + +2001-11-17 Ravi Pratap + + * expression.cs (ArrayCreation::ValidateInitializers): Implement + bits to provide dimension info is user skips doing that. + + Update second constructor to store the rank correctly. + +2001-11-16 Ravi Pratap + + * expression.cs (ArrayCreation::ValidateInitializers): Poke around + and try to implement. + + * ../errors/cs0150.cs : Add. + + * ../errors/cs0178.cs : Add. + +2001-11-16 Miguel de Icaza + + * statement.cs: Implement foreach on multi-dimensional arrays. + + * parameter.cs (Parameters.GetParameterByName): Also lookup the + name of the params argument. + + * expression.cs: Use EmitStoreOpcode to get the right opcode while + initializing the array. + + (ArrayAccess.EmitStoreOpcode): move the opcode generation here, so + we can use this elsewhere. + + * statement.cs: Finish implementation of foreach for single + dimension arrays. + + * cs-parser.jay: Use an out-of-band stack to pass information + around, I wonder why I need this. + + foreach_block: Make the new foreach_block the current_block. + + * parameter.cs (Parameters.GetEmptyReadOnlyParameters): New + function used to return a static Parameters structure. Used for + empty parameters, as those are created very frequently. + + * cs-parser.jay, class.cs: Use GetEmptyReadOnlyParameters + +2001-11-15 Ravi Pratap + + * interface.cs : Default modifier is private, not public. The + make verify test passes again. + +2001-11-15 Ravi Pratap + + * support.cs (ReflectionParameters): Fix logic to determine + whether the last parameter is a params one. Test 9 passes again. + + * delegate.cs (Populate): Register the builders we define with + RegisterParameterForBuilder. Test 19 passes again. + + * cs-parser.jay (property_declaration): Reference $6 instead + of $$ to get at the location. + + (indexer_declaration): Similar stuff. + + (attribute): Ditto. + + * class.cs (Property): Register parameters for the Get and Set methods + if they exist. Test 23 passes again. + + * expression.cs (ArrayCreation::Emit): Pass null for the method in the + call to EmitArguments as we are sure there aren't any params arguments. + Test 32 passes again. + + * suppor.cs (ParameterDesc, ParameterModifier): Fix trivial bug causing + IndexOutOfRangeException. + + * class.cs (Property::Define): Register property using TypeManager.RegisterProperty + Test 33 now passes again. + +2001-11-15 Miguel de Icaza + + * cs-parser.jay: Kill horrendous hack ($??? = lexer.Location) that + broke a bunch of things. Will have to come up with a better way + of tracking locations. + + * statement.cs: Implemented foreach for single dimension arrays. + +2001-11-09 Miguel de Icaza + + * enum.cs (Enum.Emit): Delay the lookup of loc until we run into + an error. This removes the lookup from the critical path. + + * cs-parser.jay: Removed use of temporary_loc, which is completely + broken. + +2001-11-14 Miguel de Icaza + + * support.cs (ReflectionParameters.ParameterModifier): Report + whether the argument is a PARAMS argument or not. + + * class.cs: Set the attribute `ParamArrayAttribute' on the + parameter argument. + + * typemanager.cs: Define param_array_type (ParamArrayAttribute) + and cons_param_array_attribute (ConstructorInfo for + ParamArrayAttribute)., + + * codegen.cs: Emit the return using the `Return' statement, that + way we can report the error correctly for missing return values. + + * class.cs (Method.Emit): Clean up. + + * expression.cs (Argument.Resolve): Take another argument: the + location where this argument is used. Notice that this is not + part of the "Argument" class as to reduce the size of the + structure (we know the approximate location anyways). + + Test if the argument is a variable-reference, if not, then + complain with a 206. + + (Argument.Emit): Emit addresses of variables. + + (Argument.FullDesc): Simplify. + + (Invocation.DoResolve): Update for Argument.Resolve. + + (ElementAccess.DoResolve): ditto. + + * delegate.cs (DelegateInvocation.Emit): Invocation of Invoke + method should be virtual, as this method is always virtual. + + (NewDelegate.DoResolve): Update for Argument.Resolve. + + * class.cs (ConstructorInitializer.DoResolve): ditto. + + * attribute.cs (Attribute.Resolve): ditto. + +2001-11-13 Miguel de Icaza + + * statement.cs (Foreach.Emit): Use EmitAssign instead of Store. + + * expression.cs (ParameterReference): Drop IStackStorage and implement + IAssignMethod instead. + + (LocalVariableReference): ditto. + + * ecore.cs (FieldExpr): Drop IStackStorage and implement + IAssignMethod instead. + +2001-11-13 Miguel de Icaza + + * parameter.cs, expression.cs, class.cs, ecore.cs: Made all + enumerations that are used in heavily used structures derive from + byte in a laughable and pathetic attempt to reduce memory usage. + This is the kind of pre-optimzations that you should not do at + home without adult supervision. + + * expression.cs (UnaryMutator): New class, used to handle ++ and + -- separatedly from the other unary operators. Cleans up the + code, and kills the ExpressionStatement dependency in Unary. + + (Unary): Removed `method' and `Arguments' from this class, making + it smaller, and moving it all to SimpleCall, so I can reuse this + code in other locations and avoid creating a lot of transient data + strucutres when not required. + + * cs-parser.jay: Adjust for new changes. + +2001-11-11 Miguel de Icaza + + * enum.cs (Enum.Populate): If there is a failure during + definition, return + + * cs-parser.jay (opt_enum_base): we used to catch type errors + here, but this is really incorrect. The type error should be + catched during semantic analysis. + +2001-12-11 Ravi Pratap + + * cs-parser.jay (operator_declarator, conversion_operator_declarator): Set + current_local_parameters as expected since I, in my stupidity, had forgotten + to do this :-) + + * attribute.cs (GetValidPlaces): Fix stupid bug. + + * class.cs (Method::Emit): Perform check on applicability of attributes. + + (Constructor::Emit): Ditto. + + (Field::Emit): Ditto. + + (Field.Location): Store location information. + + (Property, Event, Indexer, Operator): Ditto. + + * cs-parser.jay (field_declaration): Pass in location for each field. + + * ../errors/cs0592.cs : Add. + +2001-11-12 Ravi Pratap + + * typemanager.cs (attribute_usage_type): New static member for System.AttributeUsage. + + (InitCoreTypes): Update accordingly. + + (RegisterAttrType, LookupAttr): Implement. + + * attribute.cs (Attribute.Targets, AllowMultiple, Inherited): New fields to hold + info about the same. + + (Resolve): Update to populate the above as necessary. + + (Error592): Helper. + + (GetValidPlaces): Helper to the above. + + (CheckAttribute): Implement to perform validity of attributes on declarative elements. + + * class.cs (TypeContainer::Emit): Update attribute emission code to perform checking etc. + +2001-11-12 Ravi Pratap + + * attribute.cs (Attribute::Resolve): Expand to handle named arguments too. + + * ../errors/cs0617.cs : Add. + +2001-11-11 Ravi Pratap + + * enum.cs (Emit): Rename to Populate to be more consistent with what + we expect it to do and when exactly it is called. + + * class.cs, rootcontext.cs : Update accordingly. + + * typemanager.cs (RegisterField, GetValue): Workarounds for the fact that + FieldInfo.GetValue does not work on dynamic types ! S.R.E lameness strikes again ! + + * enum.cs (Populate): Register fields with TypeManager.RegisterField. + + * expression.cs (MemberAccess.DoResolve): Adjust code to obtain the value + of a fieldinfo using the above, when dealing with a FieldBuilder. + +2001-11-10 Ravi Pratap + + * ../errors/cs0031.cs : Add. + + * ../errors/cs1008.cs : Add. + + * ../errrors/cs0543.cs : Add. + + * enum.cs (DefineEnum): Check the underlying type and report an error if not a valid + enum type. + + (FindMembers): Implement. + + * typemanager.cs (FindMembers): Re-write to call the appropriate methods for + enums and delegates too. + + (enum_types): Rename to builder_to_enum. + + (delegate_types): Rename to builder_to_delegate. + + * delegate.cs (FindMembers): Implement. + +2001-11-09 Ravi Pratap + + * typemanager.cs (IsEnumType): Implement. + + * enum.cs (Emit): Re-write parts to account for the underlying type + better and perform checking etc. + + (GetNextDefaultValue): Helper to ensure we don't overshoot max value + of the underlying type. + + * literal.cs (GetValue methods everywhere): Perform bounds checking and return + value + + * enum.cs (error31): Helper to report error #31. + + * cs-parser.jay (enum_declaration): Store location of each member too. + + * enum.cs (member_to_location): New hashtable. + + (AddEnumMember): Update location hashtable. + + (Emit): Use the location of each member while reporting errors. + +2001-11-09 Miguel de Icaza + + * cs-parser.jay: A for_initializer if is a + local_variable_declaration really ammount to have an implicit + block with the variable declaration and no initializer for for. + + * statement.cs (For.Emit): Cope with null initializers. + + This fixes the infinite loop on for initializers. + +2001-11-08 Miguel de Icaza + + * enum.cs: More cleanup. + + * ecore.cs: Remove dead code. + + * class.cs (Property.Emit): More simplification. + (Event.Emit): ditto. + + Reworked to have less levels of indentation. + +2001-11-08 Ravi Pratap + + * class.cs (Property): Emit attributes. + + (Field): Ditto. + + (Event): Ditto. + + (Indexer): Ditto. + + (Operator): Ditto. + + * enum.cs (Emit): Ditto. + + * rootcontext.cs (ResolveTree, EmitCode, CloseTypes): Do the same for + Enums too. + + * class.cs (Field, Event, etc.): Move attribute generation into the + Emit method everywhere. + + * enum.cs (Enum): Revamp to use the same definition semantics as delegates so + we have a DefineEnum, CloseEnum etc. The previous way of doing things was not right + as we had no way of defining nested enums ! + + * rootcontext.cs : Adjust code accordingly. + + * typemanager.cs (AddEnumType): To keep track of enum types separately. + +2001-11-07 Ravi Pratap + + * expression.cs (EvalConstantExpression): Move into ecore.cs + + * enum.cs (Enum): Rename some members and make them public and readonly + according to our convention. + + * modifiers.cs (EnumAttr): Implement as we need to set only visibility flags, + nothing else. + + * enum.cs (Enum::Define): Use the above instead of TypeAttr. + + (Enum::Emit): Write a simple version for now which doesn't try to compute + expressions. I shall modify this to be more robust in just a while. + + * class.cs (TypeContainer::Emit): Make sure we include Enums too. + + (TypeContainer::CloseType): Create the Enum types too. + + * attribute.cs (Resolve): Use the new Reduce method instead of EvalConstantExpression. + + * expression.cs (EvalConstantExpression): Get rid of completely. + + * enum.cs (Enum::Emit): Use the new expression reducer. Implement assigning + user-defined values and other cases. + + (IsValidEnumLiteral): Helper function. + + * expression.cs (ExprClassfromMemberInfo): Modify to not do any literalizing + out there in the case we had a literal FieldExpr. + + (MemberAccess:DoResolve): Do the literalizing of the FieldExpr here. + + (Literalize): Revamp a bit to take two arguments. + + (EnumLiteral): New class which derives from Literal to wrap enum literals. + +2001-11-06 Ravi Pratap + + * cs-parser.jay (compilation_unit): Remove extra opt_attributes for now. + + * expression.cs (ArrayCreation::ValidateInitializers): Implement. + + (Resolve): Use the above to ensure we have proper initializers. + +2001-11-05 Ravi Pratap + + * expression.cs (Expression::EvalConstantExpression): New method to + evaluate constant expressions. + + * attribute.cs (Attribute::Resolve): Modify bits to use the above function. + +2001-11-07 Miguel de Icaza + + * expression.cs (ArrayCreation.Emit): Some bits to initialize data + in an array. + + (Binary.ResolveOperator): Handle operator != (object a, object b) + and operator == (object a, object b); + + (Binary.DoNumericPromotions): Indicate whether the numeric + promotion was possible. + + (ArrayAccess.DoResolve, ArrayAccess.Emit, ArrayAccess.EmitAssign): + Implement. + + Made the ArrayAccess implement interface IAssignMethod instead of + IStackStore as the order in which arguments are passed reflects + this. + + * assign.cs: Instead of using expr.ExprClass to select the way of + assinging, probe for the IStackStore/IAssignMethod interfaces. + + * typemanager.cs: Load InitializeArray definition. + + * rootcontext.cs (RootContext.MakeStaticData): Used to define + static data that can be used to initialize arrays. + +2001-11-05 Miguel de Icaza + + * expression.cs: Handle operator== and operator!= for booleans. + + (Conditioal.Reduce): Implement reducer for the ?: operator. + + (Conditional.Resolve): Implement dead code elimination. + + (Binary.Resolve): Catch string literals and return a new + concatenated string. + + (Unary.Reduce): Implement reduction of unary expressions. + + * ecore.cs: Split out the expression core handling here. + + (Expression.Reduce): New method used to perform constant folding + and CSE. This is needed to support constant-expressions. + + * statement.cs (Statement.EmitBoolExpression): Pass true and false + targets, and optimize for !x. + +2001-11-04 Ravi Pratap + + * attribute.cs (Attribute::Resolve): Implement guts. Note that resolution + of an attribute gives us a CustomAttributeBuilder which we use accordingly to + set custom atttributes. + + * literal.cs (Literal::GetValue): New abstract method to return the actual + value of the literal, cast as an object. + + (*Literal): Implement GetValue method. + + * cs-parser.jay (positional_argument_list, named_argument_list): Add not just plain + expressions to the arraylist but objects of type Argument. + + * class.cs (TypeContainer::Emit): Emit our attributes too. + + (Method::Emit, Constructor::Emit): Ditto. + + * cs-parser.jay (constructor_declaration): Set attributes too, which we seemed + to be ignoring earlier. + +2001-11-03 Ravi Pratap + + * attribute.cs (AttributeSection::Define): Implement to do the business + of constructing a CustomAttributeBuilder. + + (Attribute): New trivial class. Increases readability of code. + + * cs-parser.jay : Update accordingly. + + (positional_argument_list, named_argument_list, named_argument): New rules + + (attribute_arguments): Use the above so that we are more correct. + +2001-11-02 Ravi Pratap + + * expression.cs (Invocation::IsParamsMethodApplicable): Implement + to perform all checks for a method with a params parameter. + + (Invocation::OverloadResolve): Update to use the above method and therefore + cope correctly with params method invocations. + + * support.cs (InternalParameters::ParameterDesc): Provide a desc for + params too. + + * class.cs (ConstructorInitializer::Resolve): Make sure we look for Non-public + constructors in our parent too because we can't afford to miss out on + protected ones ;-) + + * attribute.cs (AttributeSection): New name for the class Attribute + + Other trivial changes to improve readability. + + * cs-parser.jay (opt_attributes, attribute_section etc.): Modify to + use the new class names. + +2001-11-01 Ravi Pratap + + * class.cs (Method::Define): Complete definition for params types too + + (Indexer::Define): Ditto. + + * support.cs (InternalParameters::ParameterType, ParameterDesc, ParameterModifier): + Cope everywhere with a request for info about the array parameter. + +2001-11-01 Ravi Pratap + + * tree.cs (RecordNamespace): Fix up to check for the correct key. + + * cs-parser.jay (GetQualifiedIdentifier): New Helper method used in + local_variable_type to extract the string corresponding to the type. + + (local_variable_type): Fixup the action to use the new helper method. + + * codegen.cs : Get rid of RefOrOutParameter, it's not the right way to + go. + + * expression.cs : Clean out code which uses the above. + +2001-10-31 Ravi Pratap + + * typemanager.cs (RegisterMethod): Check if we already have an existing key + and bale out if necessary by returning a false. + + (RegisterProperty): Ditto. + + * class.cs (everywhere): Check the return value from TypeManager.RegisterMethod + and print out appropriate error messages. + + * interface.cs (everywhere): Ditto. + + * cs-parser.jay (property_declaration, event_declaration, indexer_declaration): Pass + location to constructor. + + * class.cs (Property, Event, Indexer): Update accordingly. + + * ../errors/cs111.cs : Added. + + * expression.cs (Invocation::IsApplicable): New static method to determine applicability + of a method, as laid down by the spec. + + (Invocation::OverloadResolve): Use the above method. + +2001-10-31 Ravi Pratap + + * support.cs (InternalParameters): Get rid of crap taking in duplicate info. We + now take a TypeContainer and a Parameters object. + + (ParameterData): Modify return type of ParameterModifier method to be + Parameter.Modifier and not a string. + + (ReflectionParameters, InternalParameters): Update accordingly. + + * expression.cs (Argument::GetParameterModifier): Same here. + + * support.cs (InternalParameters::ParameterType): Find a better way of determining + if we are a ref/out parameter. Actually, the type shouldn't be holding the '&' + symbol in it at all so maybe this is only for now. + +2001-10-30 Ravi Pratap + + * support.cs (InternalParameters): Constructor now takes an extra argument + which is the actual Parameters class. + + (ParameterDesc): Update to provide info on ref/out modifiers. + + * class.cs (everywhere): Update call to InternalParameters to pass in + the second argument too. + + * support.cs (ParameterData): Add ParameterModifier, which is a method + to return the modifier info [ref/out etc] + + (InternalParameters, ReflectionParameters): Implement the above. + + * expression.cs (Argument::ParameterModifier): Similar function to return + info about the argument's modifiers. + + (Invocation::OverloadResolve): Update to take into account matching modifiers + too. + + * class.cs (Indexer::Define): Actually define a Parameter object and put it onto + a new SetFormalParameters object which we pass to InternalParameters. + +2001-10-30 Ravi Pratap + + * expression.cs (NewArray): Merge into the ArrayCreation class. + +2001-10-29 Ravi Pratap + + * expression.cs (NewArray): Merge classes NewBuiltinArray and + NewUserdefinedArray into one as there wasn't much of a use in having + two separate ones. + + * expression.cs (Argument): Change field's name to ArgType from Type. + + (Type): New readonly property which returns the proper type, taking into + account ref/out modifiers. + + (everywhere): Adjust code accordingly for the above. + + * codegen.cs (EmitContext.RefOrOutParameter): New field to determine + whether we are emitting for a ref or out parameter. + + * expression.cs (Argument::Emit): Use the above field to set the state. + + (LocalVariableReference::Emit): Update to honour the flag and emit the + right stuff. + + * parameter.cs (Attributes): Set the correct flags for ref parameters. + + * expression.cs (Argument::FullDesc): New function to provide a full desc. + + * support.cs (ParameterData): Add method ParameterDesc to the interface. + + (ReflectionParameters, InternalParameters): Implement the above method. + + * expression.cs (Invocation::OverloadResolve): Use the new desc methods in + reporting errors. + + (Invocation::FullMethodDesc): Ditto. + +2001-10-29 Miguel de Icaza + + * cs-parser.jay: Add extra production for the second form of array + creation. + + * expression.cs (ArrayCreation): Update to reflect the above + change. + + * Small changes to prepare for Array initialization. + 2001-10-28 Miguel de Icaza * typemanager.cs (ImplementsInterface): interface might be null;