* expression.cs (This::Emit): Implement.
(This::Resolve): Implement.
(TypeOf:Resolve): Implement.
(Expression::ResolveSimpleName): Add an implicit this to instance
field references.
(MemberAccess::Resolve): Deal with Parameters and Fields.
Bind instance variable to Field expressions.
(FieldExpr::Instance): New field used to track the expression that
represents the object instance.
(FieldExpr::Resolve): Track potential errors from MemberLookup not
binding
(FieldExpr::Emit): Implement.
* codegen.cs (EmitIf, EmitStatement, EmitBlock): Propagate whether
the last instruction contains a return opcode to avoid generating
the last `ret' instruction (this generates correct code, and it is
nice to pass the peverify output).
* class.cs (TypeContainer::EmitFieldInitializers): Implement field
initializer for static and instance variables.
(Constructor::Emit): Allow initializer to be null in the case of
static constructors. Only emit initializer for instance
constructors.
(TypeContainer::FindMembers): Return a null array if there are no
matches.
Also fix the code for the MemberTypes.Method branch, as it was not
scanning that for operators (or tried to access null variables before).
* assign.cs (Assign::Emit): Handle instance and static fields.
* TODO: Updated.
* driver.cs: Stop compilation if there are parse errors.
* cs-parser.jay (constructor_declaration): Provide default base
initializer for non-static constructors.
(constructor_declarator): Do not provide a default base
initializers if none was specified.
Catch the fact that constructors should not have parameters.
* class.cs: Do not emit parent class initializers for static
constructors, that should be flagged as an error.
svn path=/trunk/mcs/; revision=869
* class.cs (TypeContainer::AddConstructor): Fix the check to
compare against Name, not Basename.
(Operator::OpType): Change Plus and Minus to Add and Subtract.
* cs-parser.jay : Update accordingly.
* class.cs (TypeContainer::FindMembers): For the case where we are searching
for methods, don't forget to look into the operators too.
(RegisterMethodBuilder): Helper method to take care of this for
methods, constructors and operators.
(Operator::Define): Completely revamp.
(Operator.OperatorMethod, MethodName): New fields.
(TypeContainer::Populate): Move the registering of builders into
RegisterMethodBuilder.
(Operator::Emit): Re-write.
* expression.cs (Binary::Emit): Comment out code path to emit method
invocation stuff for the case when we have a user defined operator. I am
just not able to get it right !
svn path=/trunk/mcs/; revision=867
* x86.brg: added some rules to optimize code
* testjit.c (get_address): use a binary search to get the address
(main): added an option to debug the jit (-d)
svn path=/trunk/mono/; revision=866
* expression.cs (Expression::OverloadResolve): Drop TypeContainer
argument.
(Expression::MemberLookup): Provide a version that allows to
specify the MemberTypes and BindingFlags.
* statement.cs (Block::GetVariableInfo): Forgot to recurse here,
so it was not fetching variable information from outer blocks.
* modifiers.cs: (Modifiers::TypeAttr): Invert condition on
Beforefieldinit as it was buggy.
* rootcontext.cs (::LookupInterfaceOrClass): Removed an Error -200
that Ravi put here.
* class.cs (Constructor::Emit): Only emit if block is not null.
(TypeContainer::EmitDefaultConstructor): Removed routine, now we
deal with this by semantically definining it as if the user had
done it.
(TypeContainer::FindMembers): Removed ad-hoc hack to deal with
constructors as we now "emit" them at a higher level.
(TypeContainer::DefineDefaultConstructor): Used to define the
default constructors if none was provided.
(ConstructorInitializer): Add methods Resolve and Emit.
* expression.cs: Cast to ConstructorInfo instead of MethodInfo
svn path=/trunk/mcs/; revision=857
* class.cs (TypeContainer::EmitDefaultConstructor): Register
the default constructor builder with our hashtable for methodbuilders
to methodcores.
* expression.cs (Invocation::OverloadResolve): Add a check for pd == null
and argument_count is 0 in which case we have a match.
(Binary::ResolveOperator): More null checking and miscellaneous coding
style cleanup.
svn path=/trunk/mcs/; revision=852
* rootcontext.cs (IsNameSpace): Compare against null.
* everywhere : Correct spelling to 'Greater' and to 'Subtract'
* class.cs (Operator::OpType): Change names to match the ones in Binary::Operator
and Unary::Operator.
* cs-parser.jay (operator_declaration, CheckBinaryOperator, CheckUnaryOperator): Update
accordingly.
* expression.cs (Binary::method): New member to hold the MethodBase for the case when
we have overloaded operators.
(Binary::ResolveOperator): Implement the part which does the operator overload
resolution.
* class.cs (Operator::Emit): Implement.
(TypeContainer::Emit): Emit the operators we have too.
* expression.cs (Binary::Emit): Update to emit the appropriate code for
the case when we have a user-defined operator.
svn path=/trunk/mcs/; revision=843
* x86.brg: emit real code for calls
* testjit.c (create_jit_trampoline): creates a function to trigger jit
compilation.
(mono_compile_method): reversed argument order
svn path=/trunk/mono/; revision=842
* class.cs (EmitStaticFieldInitializers, EmitFieldInitializers): Make public.
(TypeContainer::EmitConstructor): Remove and move code into Contructor::Emit.
(Constructor::Emit): Implement.
(EmitStaticFieldInitializers, EmitFieldInitializers): Ensure we return immediately
if we have no work to do.
(TypeContainer::Emit): Pass in TypeContainer as argument to the constructor's
Emit method.
* interface.cs (Interface::InterfaceAttr): Re-write to be more correct and complete.
(Interface::IsTopLevel): Add. Same as TypeContainer::IsTopLevel.
* class.cs (TypeContainer::IsTopLevel): Modify to use parent.Parent instead
of parent.parent.
svn path=/trunk/mcs/; revision=832
* tree.cs (Tree::namespaces): New hashtable to keep track of namespaces
in the source.
(Tree::RecordNamespace): Method to do what the name says ;-)
(Tree::Namespaces): Property to get at the namespaces hashtable.
* cs-parser.jay (namespace_declaration): Call RecordNamespace to
keep track.
* rootcontext.cs (IsNamespace): Fixed it :-)
svn path=/trunk/mcs/; revision=827
* class.cs (TypeContainer::FindMembers): Add support for
constructors.
(MethodCore): New class that encapsulates both the shared aspects
of a Constructor and a Method.
(Method, Constructor): Factored pieces into MethodCore.
* driver.cs: Added --fatal which makes errors throw exceptions.
Load System assembly as well as part of the standard library.
* report.cs: Allow throwing exceptions on errors for debugging.
* modifiers.cs: Do not use `parent', instead use the real type
container to evaluate permission settings.
* class.cs: Put Ravi's patch back in. He is right, and we will
have to cope with the
svn path=/trunk/mcs/; revision=826
* class.cs: Reveted lsat change from Ravi to IsTopLevel. That is
incorrect. IsTopLevel is not used to tell whether an object is
root_types or not (that can be achieved by testing this ==
root_types). But to see if this is a top-level *class* (not
necessarly our "toplevel" container).
svn path=/trunk/mcs/; revision=823
* x86.brg: branch addresses are now resolved
* testjit.c (compute_branches): compute address of branches
* x86.brg: emit real x86 instructions
* testjit.c: call objdump to disassemble the output
svn path=/trunk/mono/; revision=822
* class.cs (TypeContainer::TypeAttr): Remove property code and move it into
Modifiers.TypeAttr. This should just be a call to that method.
* modifiers.cs (TypeAttr): Re-write and take an extra argument, the TypeContainer
object so that we can determine if we are top-level or not.
* delegate.cs (Delegate::Define): Update call to TypeAttr method to pass in the
TypeContainer too.
* enum.cs (Enum::Define): Ditto.
* modifiers.cs (FieldAttr): Re-write.
* class.cs (TypeContainer::IsTopLevel): Change accessibility to public.
(TypeContainer::HaveStaticConstructor): New property to provide access
to precisely that info.
* modifiers.cs (MethodAttr): Re-write.
(EventAttr): Remove altogether as there seems to be no ostensible use for it.
* class.cs (TypeContainer::IsTopLevel): Re-write. root_types doesn't seem to be the parent
of top-level types as claimed.
svn path=/trunk/mcs/; revision=816
* /mcs/class/makefile:
/mcs/class/corlib/makefile:
/mcs/mcs/makefile:
/toos/makefile:
use /cygdrive/ instead of //. Old method of
accessing drives under cygwin is now obsolete with version
1.3.3 of the cygwin DLL
* /mcs/System/System.Collections.Specialized/ChangeLog:
Forgot to commit this for a while. Sorry 'bout that.
svn path=/trunk/mcs/; revision=815
* expression.cs (MemberLookup): Fruitless attempt to lookup
constructors. Maybe I need to emit default constructors? That
might be it (currently .NET emits this for me automatically).
(Invocation::OverloadResolve): Cope with Arguments == null.
(Invocation::EmitArguments): new function, shared by the new
constructor and us.
(Invocation::Emit): Handle static and instance methods. Emit
proper call instruction for virtual or non-virtual invocations.
(New::Emit): Implement.
(New::Resolve): Implement.
(MemberAccess:Resolve): Implement.
(MethodGroupExpr::InstanceExpression): used conforming to the spec
to track instances.
(FieldExpr::Resolve): Set type.
* support.cs: Handle empty arguments.
* cs-parser.jay (CompositeLookup, QualifierIdentifier,
SimpleLookup): Auxiliary routines to help parse a qualifier
identifier.
Update qualifier_identifier rule.
* codegen.cs: Removed debugging messages.
* class.cs: Make this a global thing, this acts just as a "key" to
objects that we might have around.
(Populate): Only initialize method_builders_to_methods once.
* expression.cs (PropertyExpr): Initialize type from the
PropertyType.
svn path=/trunk/mcs/; revision=814
* codegen.cs (EmitContext::EmitBoolExpression): Use propper
Resolve pattern. Attempt to implicitly convert value to boolean.
Emit code.
* expression.cs: Set the type for the int32/int32 argument case.
(Binary::ResolveOperator): Set the return type to boolean for
comparission operators
* typemanager.cs: Remove debugging print code.
(Invocation::Resolve): resolve type.
svn path=/trunk/mcs/; revision=806
* class.cs: Allocate a MemberInfo of the correct size, as the code
elsewhere depends on the test to reflect the correct contents.
(Method::) Keep track of parameters, due to System.Reflection holes
(TypeContainer::Populate): Keep track of MethodBuilders to Method
mapping here.
(TypeContainer::FindMembers): Use ArrayList and then copy an array
of the exact size and return that.
(Class::LookupMethodByBuilder): New function that maps
MethodBuilders to its methods. Required to locate the information
on methods because System.Reflection bit us again.
* support.cs: New file, contains an interface ParameterData and
two implementations: ReflectionParameters and InternalParameters
used to access Parameter information. We will need to grow this
as required.
* expression.cs (Invocation::GetParameterData): implement a cache
and a wrapper around the ParameterData creation for methods.
(Invocation::OverloadResolve): Use new code.
svn path=/trunk/mcs/; revision=805
* x86.brg: use the right offsets to access local variables
and arguments.
* emit-x86.c: only save/restore callee saved registers if they are
really modified.
* testjit.c (tree_allocate_regs): use the new MonoRegSet to
allocate registers.
(mono_compile_method): changed the tree for mothod calls
* regset.h: impl.
* regset.c: impl.
svn path=/trunk/mono/; revision=803
* class.cs (TypeContainer::EmitField): Remove and move into
(Field::Define): here and modify accordingly.
(Field.FieldBuilder): New member.
(TypeContainer::Populate): Update accordingly.
(TypeContainer::FindMembers): Implement.
svn path=/trunk/mcs/; revision=799
* parameter.cs (GetParameterInfo): Use a type cache to compute
things only once, and to reuse this information
* expression.cs (LocalVariableReference::Emit): Implement.
(OpcodeCast::Emit): fix.
(ParameterReference::Resolve): Implement.
(ParameterReference::Emit): Implement.
* cs-parser.jay: Fix bug introduced by Ravi, variable initializers
that are expressions need to stay as Expressions.
* typemanager.cs (CSharpName): Returns the C# name of a type if
possible.
* expression.cs (Expression::ConvertImplicit): New function that
implements implicit type conversions.
svn path=/trunk/mcs/; revision=797
* expression.cs (LocalVariableReference::Emit): Implement.
(OpcodeCast::Emit): fix.
* cs-parser.jay: Fix bug introduced by Ravi, variable initializers
that are expressions need to stay as Expressions.
svn path=/trunk/mcs/; revision=796
* typemanager.cs (CSharpName): Returns the C# name of a type if
possible.
* expression.cs (Expression::ConvertImplicit): New function that
implements implicit type conversions.
(Expression::ImplicitReferenceConversion): Implements implicit
reference conversions.
(EmptyCast): New type for transparent casts.
(OpcodeCast): New type for casts of types that are performed with
a sequence of bytecodes.
(BoxedCast): New type used for casting value types into reference
types. Emits a box opcode.
(Binary::DoNumericPromotions): Implements numeric promotions of
and computation of the Binary::Type.
(Binary::EmitBranchable): Optimization.
(Binary::Emit): Implement code emission for expressions.
* typemanager.cs (TypeManager): Added two new core types: sbyte
and byte.
svn path=/trunk/mcs/; revision=795
* class.cs (TypeContainer::FindMembers): Method which does exactly
what Type.FindMembers does, only we don't have to use reflection. No
implementation yet.
* typemanager.cs (typecontainers): New hashtable to hold the corresponding
typecontainer objects as we need to get at them.
(TypeManager::AddUserType): Overload to take an extra argument, the TypeContainer.
* rootcontext.cs : Correspondingly modify called to AddUserType to pass the
typecontainer object.
* expression.cs (MemberLookup): Modify signature to take a RootContext object instead
of just a Report object.
svn path=/trunk/mcs/; revision=793
* class.cs (Event::Define): Go back to using the prefixes "add_" and
"remove_"
(TypeContainer::Populate): Now define the delegates of the type too.
(TypeContainer.Delegates): Property to access the list of delegates defined
in the type.
* delegates.cs (Delegate::Define): Implement partially.
* modifiers.cs (TypeAttr): Handle more flags.
svn path=/trunk/mcs/; revision=791
* Makefile.am: get it to work on platforms that insist on having
a weird extension at the end of an executable name.
svn path=/trunk/mono/; revision=790
* class.cs (Indexer::Define): Fix for loop iteration condition to be just <
and not <=
(Operator::Define): Re-write logic to get types by using the LookupType method
instead of blindly doing a Type.GetType ! How stupid can I get ;-) ?
(Indexer::Define): Ditto.
(Event::Define): Ditto.
(Property::Define): Ditto.
svn path=/trunk/mcs/; revision=789
* x86.brg: Use Unix assembly syntax.
* emit-x86.c: support code, should be moved
* testjit.c: Use GPtrArrays instead of GLists, as those are very
inefficient at appends.
svn path=/trunk/mono/; revision=788
* testjit.c: Use GPtrArrays instead of GLists, as those are very
inefficient at appends.
* Renamed `create_new_leave' to `create_new_leaf'
svn path=/trunk/mono/; revision=787
* class.cs (TypeContainer::Populate): Now define operators too.
(TypeContainer.Operators): New property to access the list of operators
in a type.
(Operator.OperatorMethodBuilder): New member to hold the method builder
for the operator we are defining.
(Operator::Define): Implement.
svn path=/trunk/mcs/; revision=786
* class.cs (Event::Define): Make the prefixes of the accessor methods
addOn_ and removeOn_
* genericparser.cs (GenericParser::error): Overloaded method to handle the case
of the location being passed in too. Ideally, this should go later since all
error reporting should be done through the Report object.
* class.cs (TypeContainer.Indexers): New property to access the list of indexers.
(Populate): Iterate thru the indexers we have and define them too.
(Indexer.GetMethodBuilder, .SetMethodBuilder): New members to hold the method builders
for the get and set accessors.
(Indexer::Define): Implement.
svn path=/trunk/mcs/; revision=785
* configure.in: check for sizeof(void*) and for the architecture.
Mon Sep 10 17:26:06 CEST 2001 Paolo Molaro <[email protected]>
* Makefile.am, x86/Makefile.am: conditional compile logic
to make porting to different targets easier.
Mon Sep 10 17:24:45 CEST 2001 Paolo Molaro <[email protected]>
* Makefile.am: make it work for make distcheck.
Mon Sep 10 20:21:34 CEST 2001 Paolo Molaro <[email protected]>
* endian.h, assembly.c: fix some endianness issues.
Mon Sep 10 20:20:36 CEST 2001 Paolo Molaro <[email protected]>
* interp.c: endian fixes, comments.
svn path=/trunk/mono/; revision=783
* BooleanSwitch.cs: Make this class use it's parent class's features.
Namely, use SwitchSetting so that we can get OnSwitchSettingChanged()
to fire for free.
svn path=/trunk/mcs/; revision=774
* ChangeLog: added this file
* Switch.cs: call OnSwitchSettingChanged() when the switch setting is,
yes you gessed it, changed.
svn path=/trunk/mcs/; revision=773
* Makefile.am: change CLEANFILES line to use just '=' instead of '+='
some versions of automake complain if you try to '+=' before you '='
svn path=/trunk/mono/; revision=772
* expression.cs (Binary::Resolve): Beginning of it. I scratched
my previous implementation, did not work.
* typemanager.cs: Add a couple of missing types (the longs).
* literal.cs: Use TypeManager.bool_type instead of getting it.
* expression.cs (EventExpr): New kind of expressions.
(Expressio::ExprClassFromMemberInfo): finish
svn path=/trunk/mcs/; revision=770
* String.cs (TrimStart): Don't keep looping through the trimchars
once we've found a match.
(TrimEnd): Same here.
(Trim): And finally here.
svn path=/trunk/mcs/; revision=767
* Merge in changes and adjust code to tackle conflicts. Backed out my
code in Assign::Resolve ;-)
2001-09-08 Ravi Pratap <[email protected]>
* cs-parser.jay (CheckAttributeTarget): Modify call to error to use
instead Report.Error and also pass in the location.
(CSharpParser::Lexer): New readonly property to return the reference
to the Tokenizer object.
(declare_local_variables): Use Report.Error with location instead of plain
old error.
(CheckDef): Ditto.
* class.cs (Operator::CheckUnaryOperator): Move into cs-parser.jay.
(Operator.CheckBinaryOperator): Ditto.
* cs-parser.jay (operator_declarator): Update accordingly.
* cs-parser.jay (CheckUnaryOperator): Modify to use Report.Error
(CheckBinaryOperator): Same here.
* rootcontext.cs (LookupType): Add an extra lookup which simply does a lookup
on the name without any prefixes of namespace names etc. This is because we
already might have something already fully qualified like
'System.Console.WriteLine'
* assign.cs (Resolve): Begin implementation. Stuck ;-)
2001-09-07 Ravi Pratap <[email protected]>
* cs-tokenizer.cs (location): Return a string which also contains
the file name.
* expression.cs (ElementAccess): New class for expressions of the
type 'element access.'
(BaseAccess): New class for expressions of the type 'base access.'
(CheckedExpr, UnCheckedExpr): New classes for Checked and Unchecked expressions
respectively.
* cs-parser.jay (element_access): Implement action.
(base_access): Implement actions.
(checked_expression, unchecked_expression): Implement.
* cs-parser.jay (local_variable_type): Correct and implement.
(type_suffixes, type_suffix_list, type_suffix): Implement actions.
* cs-tokenizer.cs (real_type_suffix): Comment out the extra getchar.
* cs-parser.jay (rank_specifiers): Remove space while concatenating the type's
name and the specifiers.
* interface.cs (InterfaceAttr): New property to return the corresponding TypeAttributes
* rootcontext.cs (CreateInterface): Use the InterfaceAttr property instead of
making them all public ;-)
* cs-parser.jay (error): Remove entirely as we have an implementation in the base
class anyways.
svn path=/trunk/mcs/; revision=765
* Char.cs (IsLetterOrDigit): Implement.
(IsLower): Implement, but we need to be Unicode aware.
(IsNumber): Implement.
(IsPunctuation): Implement.
(IsWhiteSpace): Implement.
(ToUpper): Fix to subtract 32 from the ASCII value, not 33 :)
(ToLower): Same here.
svn path=/trunk/mcs/; revision=764
* x86/x86-codegen.h: fixes and x86_mov_membase_imm ().
* x86/tramp.c: implemented mono_create_method_pointer ():
creates a native pointer to a method implementation that can be
used as a normal C callback.
Fri Sep 7 18:45:38 CEST 2001 Paolo Molaro <[email protected]>
* interp.c, interp.h: make ves_exec_method () and stackval_from_data ()
non static. Implement a couple of runtime methods needed to
use delegates (ves_runtime_method ()).
Implemented ldftn opcode.
svn path=/trunk/mono/; revision=745
* Makefile.am: Use '=' to set CLEANFILES instead of '+=' since
it's the first assignment.
* ChangeLog: added this file.
svn path=/trunk/mono/; revision=740
* expression.cs (ExprClassFromMemberInfo): Return FieldExpr and
PropertyExprs.
(FieldExpr, PropertyExprs): New resolved expressions.
(SimpleName::MemberStaticCheck): Perform static checks for access
to non-static fields on static methods. Maybe this should be
generalized for MemberAccesses.
(SimpleName::ResolveSimpleName): More work on simple name
resolution.
* cs-parser.jay (primary_expression/qualified_identifier): track
the parameter index.
* codegen.cs (CodeGen::Save): Catch save exception, report error.
(EmitContext::EmitBoolExpression): Chain to expression generation
instead of temporary hack.
(::EmitStatementExpression): Put generic expression code generation.
* assign.cs (Assign::Emit): Implement variable assignments to
local variables, parameters and fields.
2001-09-06 Miguel de Icaza <[email protected]>
* statement.cs (Block::GetVariableInfo): New method, returns the
VariableInfo for a variable name in a block.
(Block::GetVariableType): Implement in terms of GetVariableInfo
* literal.cs (IntLiteral::Emit, FloatLiteral::Emit,
DoubleLiteral::Emit, CharLiteral::Emit, BoolLiteral::Emit): Implement
svn path=/trunk/mcs/; revision=736
* x86/x86-codegen.h: added x86_rdtsc() and fixes.
* x86/tramp.c: create trampolines to call pinvoke methods.
* x86/Makefile.am: create a libmonoarch convenience library.
Thu Sep 6 15:41:24 CEST 2001 Paolo Molaro <[email protected]>
* Makefile.am: link to libmonoarch.
* interp.h, interp.c: use mono_create_trampoline ().
Pass the command line arguments to Main (String[]) methods.
svn path=/trunk/mono/; revision=728
* cs-parser.jay (CheckAttributeTarget): Update to use the right error number.
* ../tests/cs0658.cs : New file to demonstrate error 0658.
* attribute.cs (Attributes): New class to encapsulate all attributes which were
being passed around as an arraylist.
(Attributes::AddAttribute): Method to add attribute sections.
* cs-parser.jay (opt_attributes): Modify actions to use the new Attributes class.
(struct_declaration): Update accordingly.
(constant_declaration): Update.
(field_declaration): Update.
(method_header): Update.
(fixed_parameter): Update.
(parameter_array): Ditto.
(property_declaration): Ditto.
(destructor_declaration): Ditto.
* class.cs (Struct::Struct): Update constructors accordingly.
(Class::Class): Ditto.
(Field::Field): Ditto.
(Method::Method): Ditto.
(Property::Property): Ditto.
(TypeContainer::OptAttribute): update property's return type.
* interface.cs (Interface.opt_attributes): New member.
(Interface::Interface): Update to take the extra Attributes argument.
* parameter.cs (Parameter::Parameter): Ditto.
* constant.cs (Constant::Constant): Ditto.
* interface.cs (InterfaceMemberBase): New OptAttributes field.
(InterfaceMemberBase::InterfaceMemberBase): Update constructor to take
the attributes as a parameter.
(InterfaceProperty): Update constructor call.
(InterfaceEvent): Ditto.
(InterfaceMethod): Ditto.
(InterfaceIndexer): Ditto.
* cs-parser.jay (interface_indexer_declaration): Update call to constructor to
pass the attributes too.
(interface_event_declaration): Ditto.
(interface_property_declaration): Ditto.
(interface_method_declaration): Ditto.
(interface_declaration): Ditto.
svn path=/trunk/mcs/; revision=726
* class.cs (Method::Define): Track the "static Main" definition to
create an entry point.
* rootcontext.cs (RootContext::EntryPoint): MethodInfo that holds the
EntryPoint if we find it.
* codegen.cs (EmitContext::EmitInvocation): Emit invocations.
(EmitContext::ig): Make this variable public.
* driver.cs: Make the default output file be the first file name
with the .exe extension.
Detect empty compilations
Handle various kinds of output targets. Handle --target and
rename -t to --dumper.
* expression.cs, literal.cs, assign.cs, constant.cs: All `Resolve'
methods inherited from Expression return now an Expression. This
will is used during the tree rewriting as we resolve them during
semantic analysis.
(Expression::MemberLookup): Implements the MemberLookup (7.3) from
the spec. Missing entirely is the information about
accessability of elements of it.
(Expression::ExprClassFromMemberInfo): New constructor for
Expressions that creates a fully initialized Expression based on
a MemberInfo that is one of Eventinfo, FieldINfo, PropertyInfo or
a Type.
(Invocation::Resolve): Begin implementing resolution of invocations.
* literal.cs (StringLiteral): Implement Emit.
svn path=/trunk/mcs/; revision=721
* autogen.sh: Fixed the section that adds $ACLOCAL_FLAGS to the
aclocal invocation, so putting aclocal files in /usr/local works
svn path=/trunk/mono/; revision=718
* cs-parser.jay (error): Add new modifier because we are hiding an inherited
member.
2001-09-04 Ravi Pratap <[email protected]>
* cs-parser.jay (attribute_arguments): Implement actions.
(attribute): Fix bug in production. Implement action.
(attribute_list): Implement.
(attribute_target): Implement.
(attribute_target_specifier, opt_target_specifier): Implement
(CheckAttributeTarget): New method to check if the attribute target
is valid.
(attribute_section): Implement.
(opt_attributes): Implement.
* attribute.cs : New file to handle attributes.
(Attribute): Class to hold attribute info.
* cs-parser.jay (opt_attribute_target_specifier): Remove production
(attribute_section): Modify production to use 2 different rules to
achieve the same thing. 1 s/r conflict down !
Clean out commented, useless, non-reducing dimension_separator rules.
* class.cs (TypeContainer.attributes): New member to hold list
of attributes for a type.
(Struct::Struct): Modify to take one more argument, the attribute list.
(Class::Class): Ditto.
(Field::Field): Ditto.
(Method::Method): Ditto.
(Property::Property): Ditto.
* cs-parser.jay (struct_declaration): Update constructor call to
pass in the attributes too.
(class_declaration): Ditto.
(constant_declaration): Ditto.
(field_declaration): Ditto.
(method_header): Ditto.
(fixed_parameter): Ditto.
(parameter_array): Ditto.
(property_declaration): Ditto.
* constant.cs (Constant::Constant): Update constructor similarly.
Use System.Collections.
svn path=/trunk/mcs/; revision=715
Updates the enumerations to contain [Flags] (Sergey)
Updated enumerations to have the same values as ECMA (Sergey).
Added various new methods to Type.cs
Added all the classes that were not being compiled in the past to the build.
Fix various small typos to get things compiling
Miguel
svn path=/trunk/mcs/; revision=702
* class.cs (TypeContainer::AddDelegate): New method to add a delegate.
(TypeContainer.delegates): New member to hold list of delegates.
* cs-parser.jay (delegate_declaration): Implement the action correctly
this time as I seem to be on crack ;-)
svn path=/trunk/mcs/; revision=699
* rootcontext.cs (RootContext::IsNamespace): new function, used to
tell whether an identifier represents a namespace.
* expression.cs (NamespaceExpr): A namespace expression, used only
temporarly during expression resolution.
(Expression::ResolveSimpleName, ::ResolvePrimary, ::ResolveName):
utility functions to resolve names on expressions.
2001-09-01 Miguel de Icaza <[email protected]>
* codegen.cs: Add hook for StatementExpressions.
* class.cs: Fix inverted test for static flag in methods.
svn path=/trunk/mcs/; revision=698
* class.cs (Operator::CheckUnaryOperator): Correct error number used
to make it coincide with MS' number.
(Operator::CheckBinaryOperator): Ditto.
* ../errors/errors.txt : Remove error numbers added earlier.
* ../errors/cs1019.cs : Test case for error # 1019
* ../errros/cs1020.cs : Test case for error # 1020
* cs-parser.jay : Clean out commented cruft.
(dimension_separators, dimension_separator): Comment out. Ostensibly not
used anywhere - non-reducing rule.
(namespace_declarations): Non-reducing rule - comment out.
* enum.cs (Enum::AddEnum): Rename to AddEnumMember as I was getting confused
with TypeContainer::AddEnum.
* delegate.cs : New file for delegate handling classes.
(Delegate): Class for declaring delegates.
* makefile : Update.
* cs-parser.jay (delegate_declaration): Implement.
svn path=/trunk/mcs/; revision=696
* class.cs (Event::Define): Implement.
(Event.EventBuilder): New member.
* class.cs (TypeContainer::Populate): Update to define all enums and events
we have.
(Events): New property for the events arraylist we hold. Shouldn't we move to using
readonly fields for all these cases ?
2001-08-31 Ravi Pratap <[email protected]>
* class.cs (Property): Revamp to use the convention of making fields readonly.
Accordingly modify code elsewhere.
* class.cs : Apply patch from Mr. Mandar <[email protected]> for implementing
the Define method of the Property class.
* class.cs : Clean up applied patch and update references to variables etc. Fix
trivial bug.
(TypeContainer::Populate): Update to define all the properties we have. Also
define all enumerations.
* enum.cs (Define): Implement.
svn path=/trunk/mcs/; revision=694
Added support for enums;
Removed duplicated checks in Compare.Parameters;
Now has option to ignore missing types instead of reporting fatal-erros;
svn path=/trunk/mcs/; revision=691
* cs-parser.jay (overloadable_operator): The semantic value is an
enum of the Operator class.
(operator_declarator): Implement actions.
(operator_declaration): Implement.
* class.cs (Operator::CheckUnaryOperator): New static method to help in checking
validity of definitions.
(Operator::CheckBinaryOperator): Static method to check for binary operators
(TypeContainer::AddOperator): New method to add an operator to a type.
* cs-parser.jay (indexer_declaration): Added line to actually call the
AddIndexer method so it gets added ;-)
* ../errors/errors.txt : Update to include new error numbers. Are these numbers
already taken care of by the MS compiler ?
2001-08-29 Ravi Pratap <[email protected]>
* class.cs (Operator): New class for operator declarations.
(Operator::OpType): Enum for the various operators.
svn path=/trunk/mcs/; revision=688
* loader.c (mono_get_method): use pinvoke for internal call
* icall.c: use pinvoke for internal call
* loader.c (method_from_memberref): set the method name
* interp.c (ves_array_set): moved from icall.c
(ves_array_get): moved from icall.c
* icall.c: moved to metadata/icall.c
svn path=/trunk/mono/; revision=674
* interp.c: some small optimizations. Fixes to do signed
compares when needed. Change C++ comments into C.
Implemented cgt, clt. Added --opcode-count cmdline switch.
svn path=/trunk/mono/; revision=673
* class.cs (TypeContainer::AddIndexer): Remove FIXME comment. We
ostensibly handle this in semantic analysis.
* cs-parser.jay (general_catch_clause): Comment out
(specific_catch_clauses, specific_catch_clause): Ditto.
(opt_general_catch_clause, opt_specific_catch_clauses): Ditto
(catch_args, opt_catch_args): New productions.
(catch_clause): Rewrite to use the new productions above
(catch_clauses): Modify accordingly.
(opt_catch_clauses): New production to use in try_statement
(try_statement): Revamp. Basically, we get rid of one unnecessary rule
and re-write the code in the actions to extract the specific and
general catch clauses by being a little smart ;-)
* ../tests/try.cs : Fix. It's not 'finalize' my friend, it's 'finally' !
Hooray, try and catch statements parse fine !
2001-08-28 Ravi Pratap <[email protected]>
* statement.cs (Block::GetVariableType): Fix logic to extract the type
string from the hashtable of variables.
* cs-parser.jay (event_accessor_declarations): Trivial fix. Man, how did
I end up making that mistake ;-)
(catch_clauses): Fixed gross error which made Key and Value of the
DictionaryEntry the same : $1 !!
svn path=/trunk/mcs/; revision=667
* NameObjectCollectionBase.cs: Add stub implementation
* common.src: Add NameObjectCollectionBase to the build
* NameValueCollection.cs: add 'override' to CopyTo(). Maybe
this code actually belongs in the superclass.
svn path=/trunk/mcs/; revision=664
* interp.c (ves_exec_method): better check for value types (get
the class to detect if we have a value type), implemented CEE_CONV_U1,
CEE_CONV_U2, CEE_CEQ
* class.c (mono_class_metadata_init): delayed computing of the
class size to mono_class_metadata_init ()
* mono/tests/console.cs: impl.
* mono/tests/box.cs: impl.
* mono/tests/stream-writer.cs: impl.
svn path=/trunk/mono/; revision=655
* main.c, dump.c, dump.h, get.c: added dump_table_interfaceimpl ().
Output info about interfaces when disassembling a type. Many small
changes to make the output correct assembler.
svn path=/trunk/mono/; revision=653
* class.c, class.h: add an interfaces member to MonoClass.
* image.c, image.h: add assembly_name field to MonoImage
from the assembly table.
* metadata.c, metadata.h: add mono_metadata_interfaces_from_typedef ().
svn path=/trunk/mono/; revision=652
* cs-tokenizer.cs (initTokens): Add keywords 'add' and 'remove'
* cs-parser.jay (event_declaration): Correct to remove the semicolon
when the add and remove accessors are specified.
svn path=/trunk/mcs/; revision=651
* cs-parser.jay (IndexerDeclaration): New helper class to hold
information about indexer_declarator.
(indexer_declarator): Implement actions.
(parsing_indexer): New local boolean used to keep track of whether
we are parsing indexers or properties. This is necessary because
implicit_parameters come into picture even for the get accessor in the
case of an indexer.
(get_accessor_declaration, set_accessor_declaration): Correspondingly modified.
* class.cs (Indexer): New class for indexer declarations.
(TypeContainer::AddIndexer): New method to add an indexer to a type.
(TypeContainer::indexers): New member to hold list of indexers for the
type.
2001-08-27 Ravi Pratap <[email protected]>
* cs-parser.jay (add_accessor_declaration): Implement action.
(remove_accessor_declaration): Implement action.
(event_accessors_declaration): Implement
(variable_declarators): swap statements for first rule - trivial.
* class.cs (Event): New class to hold information about event
declarations.
(TypeContainer::AddEvent): New method to add an event to a type
(TypeContainer::events): New member to hold list of events.
* cs-parser.jay (event_declaration): Implement actions.
svn path=/trunk/mcs/; revision=650
* mono/tests/*: New test cases, mostly for virtual method dispatch.
Use make testb for the slow benchmarking programs,
make test for the usual regression test checks.
svn path=/trunk/mono/; revision=645
* interp.c: merge isinst/castclass handling. Hopefully implement
the right semantics for handling callvirt correctly (changes
here and there to support it). Integrate bugfix from Dietmar quickly
so he needs to handle the cvs conflict:-)
svn path=/trunk/mono/; revision=644
* dis-cil.c, get.c: some endian fixes.
* main.c: colon-separate version numbers. Print also namespace
when outputting class information.
svn path=/trunk/mono/; revision=643
* class.c, loader.c, loader.h: More types handled in mono_class_from_mono_type ().
* metadata.c: fix small problem introduced with the latest commit.
svn path=/trunk/mono/; revision=640
* loader.c, metadata.c, metadata.h: Export mono_metadata_type_equal().
We don't need a MonoMetadata pointer anymore to compare signatures in
mono_metadata_signature_equal (), update callers.
Reduced memory usage an number of allocations for MonoMethodHeader and
MonoMethodSignature.
Mon Aug 27 12:20:32 CEST 2001 Paolo Molaro <[email protected]>
* interp.c: fix compilation and updates for changes in metadata/.
svn path=/trunk/mono/; revision=639
* cs-parser.jay (dim_separators): Implement. Make it a string
concatenating all the commas together, just as they appear.
(opt_dim_separators): Modify accordingly
(rank_specifiers): Update accordingly. Basically do the same
thing - instead, collect the brackets here.
(opt_rank_sepcifiers): Modify accordingly.
(array_type): Modify to actually return the complete type string
instead of ignoring the rank_specifiers.
(expression_list): Implement to collect the expressions
(variable_initializer): Implement. We make it a list of expressions
essentially so that we can handle the array_initializer case neatly too.
(variable_initializer_list): Implement.
(array_initializer): Make it a list of variable_initializers
(opt_array_initializer): Modify accordingly.
* expression.cs (New::NType): Add enumeration to help us
keep track of whether we have an object/delegate creation
or an array creation.
(New:NewType, New::Rank, New::Indices, New::Initializers): New
members to hold data about array creation.
(New:New): Modify to update NewType
(New:New): New Overloaded contructor for the array creation
case.
* cs-parser.jay (array_creation_expression): Implement to call
the overloaded New constructor.
2001-08-26 Ravi Pratap <[email protected]>
* class.cs (TypeContainer::Constructors): Return member
constructors instead of returning null.
svn path=/trunk/mcs/; revision=637
* typemanager.cs (InitCoreTypes): Initialize the various core
types after we have populated the type manager with the user
defined types (this distinction will be important later while
compiling corlib.dll)
* expression.cs, literal.cs, assign.cs, constant.cs: Started work
on Expression Classification. Now all expressions have a method
`Resolve' and a method `Emit'.
* codegen.cs, cs-parser.jay: Fixed the bug that stopped code
generation from working. Also add some temporary debugging
code.
svn path=/trunk/mcs/; revision=632
* interp.c: get in a dummy virtual method dispatch.
Added support for int64, native int and native uint as arguments.
Added debug enter/leave for icall and pinvoke methods, too.
Implement opcodes conv.i, conv.i8, ldelema.
svn path=/trunk/mono/; revision=630
* interp.h, interp.c: load also a MonoClass pointer when we load
an address on the stack. Implemented conv.i1, conv.i2, con.i4,
conv.u4, conv.r4, conv.r8. Print the arguments in the stack trace
and the name of the exception.
svn path=/trunk/mono/; revision=623
* class.h, class.c, loader.h, loader.c: export mono_class_from_mono_type ()
and add a couple more types to it and mono_defaults. Give an hint on
classes that need implementing in our corlib and are referenced
in mscorlib.
svn path=/trunk/mono/; revision=622
* class.h, class.c: keep track if a class is also an Enum.
* loader.c: Implement a couple more types for use in libffi
marshalling. Gives better diagnostics when failing to dlopen
a library. Set method->klass for P/Invoke methods, too.
svn path=/trunk/mono/; revision=618
* added support for non-public types;
* fixed types comparison bug,
types must be compared by-hand, Equals won't work;
* now methods also compared by their access modifiers and inheritance options;
* more extensive error reporting;
* minor internal changes;
svn path=/trunk/mcs/; revision=617
* codegen.cs: Lots of code generation pieces. This is only the
beginning, will continue tomorrow with more touches of polish. We
handle the fundamentals of if, while, do, for, return. Others are
trickier and I need to start working on invocations soon.
* gen-treedump.cs: Bug fix, use s.Increment here instead of
s.InitStatement.
* codegen.cs (EmitContext): New struct, used during code
emission to keep a context. Most of the code generation will be
here.
* cs-parser.jay: Add embedded blocks to the list of statements of
this block. So code generation proceeds in a top down fashion.
svn path=/trunk/mcs/; revision=616
* (common.src): Removed IAsyncResult as it is not on CVS yet.
* UIntPtr.cs: Removed CLSCompliant attribute before the namespace,
as it breaks the build.
svn path=/trunk/mcs/; revision=610
* class.c, class.h: add a MonoType this_arg to MonoClass that
represents a pointer to an object of the class' type that
can be used by the interpreter and later the type cache.
Add best guess alignment info for valuetype objects.
Fri Aug 24 19:34:04 CEST 2001 Paolo Molaro <[email protected]>
* interp.h, interp.c: add support for valuetypes.
svn path=/trunk/mono/; revision=603
* metadata.h, metadata.c, class.h, class.c: squeezed MonoParam
into MonoType: one less level of indirection and allocation and
simplifies quite a bit of code. Added cache for MonoTypes that are
used frequently, so that we don't need to allocate them all the time.
Fri Aug 24 16:09:20 CEST 2001 Paolo Molaro <[email protected]>
* interp.c: updates for merge of MonoParam in MonoType.
Fri Aug 24 16:10:12 CEST 2001 Paolo Molaro <[email protected]>
* get.c, main.c, get.h: updates for MonoParam merge in MonoType.
svn path=/trunk/mono/; revision=602
* SingleTagSectionHandler.cs: Added.
* DictionarySectionHandler.cs: Added.
* NameValueSectionHandler.cs: Compile errors are now fixed.
* IgnoreSectionHandler.cs: Compile errors are now fixed.
* ConfigurationSettings.cs: Added Implementation code for the entire class.
Note the LAMESPEC: in GetConfig().
svn path=/trunk/mcs/; revision=601
* class.c (mono_class_create_from_typedef): System.Enum is also a
value type, although it does not derive from System.ValueType
(maybe a bug in the ms compiler?)
* metadata.c (mono_type_size): return the right size for value types
* loader.c (mono_get_method): only initialize method header if not abstract
svn path=/trunk/mono/; revision=599
for errors because the status line that says No Errors found "lies"
Fixed the compiler errors and vow to be more careful with copy/paste
svn path=/trunk/mcs/; revision=583
* codegen.cs (EmitCode): New function, will emit the code for a
Block of code given a TypeContainer and its ILGenerator.
* statement.cs (Block): Standard public readonly optimization.
(Block::Block constructors): Link children.
(Block::Child): Child Linker.
(Block::EmitVariables): Emits IL variable declarations.
* class.cs: Drop support for MethodGroups here, delay until
Semantic Analysis.
(Method::): Applied the same simplification that I did before, and
move from Properties to public readonly fields.
(Method::ParameterTypes): Returns the parameter types for the
function, and implements a cache that will be useful later when I
do error checking and the semantic analysis on the methods is
performed.
(Constructor::GetCallingConvention): Renamed from CallingConvetion
and made a method, optional argument tells whether this is a class
or a structure to apply the `has-this' bit.
(Method::GetCallingConvention): Implement, returns the calling
convention.
(Method::Define): Defines the type, a second pass is performed
later to populate the methods.
(Constructor::ParameterTypes): implement a cache similar to the
one on Method::ParameterTypes, useful later when we do semantic
analysis.
(TypeContainer::EmitMethod): New method. Emits methods.
* expression.cs: Removed MethodGroup class from here.
* parameter.cs (Parameters::GetCallingConvention): new method.
svn path=/trunk/mcs/; revision=573
* interp.c: simplified init_class (). Make sure a class
is fully initialized before executing a method in the class.
Search for the class constructor only on beforefieldinit classes.
Implement a bunch of opcodes: br, brfalse, brtrue, beq, bge,
bgt, blt, ble, bne.un, bge.un, bgt.un, ble.un, blt.un, stind.i,
ldflda, ldsflda, ldelem.i8, stelem.i8, leave.
svn path=/trunk/mono/; revision=564
* metadata.c, loader.h, loader.c, image.h, image.c, class.h, class.c:
MonoClass now has the name and name_space fields.
MonoMethod has a pointer to its MonoClass, instead of MonoImage.
mono_get_method () takes and optional MonoClass as argument.
Removed mono_typedef_from_name() and added mono_class_token_from_name()
instead that takes advantage of a map from class names to typedef
tokens in MonoImage.
Wed Aug 22 16:34:03 CEST 2001 Paolo Molaro <[email protected]>
* interp.c: Updates for changes in metadata/. Better output in debug mode
and in the stack trace. Completed rethrow handling
svn path=/trunk/mono/; revision=559
Added implementations in Unix.cs and Windows.cs for retrieving
environment variables in a platform specific manner.
Implementations are called from Environment.cs
svn path=/trunk/mcs/; revision=554
* class.cs (TypeContainer::Populate): Drop RootContext from the
argument.
(Constructor::CallingConvention): Returns the calling convention.
(Constructor::ParameterTypes): Returns the constructor parameter
types.
(TypeContainer::AddConstructor): Keep track of default constructor
and the default static constructor.
(Constructor::) Another class that starts using `public readonly'
instead of properties.
(Constructor::IsDefault): Whether this is a default constructor.
(Field::) use readonly public fields instead of properties also.
(TypeContainer::TypeAttr, TypeContainer::AddConstructor): Keep
track of static constructors; If none is used, turn on
BeforeFieldInit in the TypeAttributes.
* cs-parser.jay (opt_argument_list): now the return can be null
for the cases where there are no arguments.
(constructor_declarator): If there is no implicit `base' or
`this', then invoke the default parent constructor.
* modifiers.cs (MethodAttr): New static function maps a set of
modifiers flags into a MethodAttributes enum
(FieldAttr): renamed from `Map'. So now we have FieldAttr,
MethodAttr, TypeAttr to represent the various mappings where the
modifiers are used.
(FieldAttr): Map also `readonly' to `FieldAttributes.InitOnly'
svn path=/trunk/mcs/; revision=544
* mono/tests/exceptions*: enhanced and added more tests for
exceptions.
Tue Aug 21 18:54:58 CEST 2001 Paolo Molaro <[email protected]>
* metadata.c: zero is not a valid alignment boundary.
Merge MONO_TYPE_VOID in default decoding code.
Tue Aug 21 18:56:19 CEST 2001 Paolo Molaro <[email protected]>
* interp.c: new macro INIT_FRAME() to properly
initialize a MonoInvocation. Fixed a couple of buglets in exception code:
increase stack pointer when pushing the exception for catch blocks,
initialize frame->ex_handler to NULL, correctly try all the
catch blocks (don't incorrectly fallback on filter handling).
Added a couple more checks where we may need to throw an
exception. Added more exception creation functions.
Changed stackval_from_data() to take the target stackval as
argument. Implemented a couple more opcodes.
* interp.h: prepare stackval for value type code.
svn path=/trunk/mono/; revision=539
* mono/Makefile.am (SUBDIRS): Remove `test' from here to allow us
to pass make distcheck
* mono/wrapper/Makefile.am (EXTRA_DIST): Include genwrapper.pl
* configure.in, Makefile.am, runtime/Makefile.am (dist-hook,
install-data-hook): Added mechanism to distribute and install the
dll files.
svn path=/trunk/mono/; revision=527
* Implemented ConditionalAttribute.cs and DebuggableAttribute.cs
* Forgot to cvs add them before I commited (cvs-newbie error, sorry)
svn path=/trunk/mcs/; revision=518
* util.c: add a space when decoding multiple flags.
* dump.c, dump.h, main.c: decode the property map and
methodsemantics tables. Disassemble property information
to .property IL directives.
* get.c: allow passing a NULL as method in dis_stringify_method ()
if a methoddef_row is given.
Mon Aug 20 19:39:00 CEST 2001 Paolo Molaro <[email protected]>
* blob.h: fix MONO_TYPE_TYPEDBYREF value.
* cil-coff.h: split MonoMSDOSHeader and add size info.
* image.c: add some consistency checks.
* metadata.c: fix row size computation: one programmer
error and one LAMESPEC. Handle MONO_TYPE_TYPEDBYREF.
add explanation for the locator routine.
Fix decoding of size in method header.
svn path=/trunk/mono/; revision=511
* assembly.c (g_concat_dir_and_file): Bring g_concat_dir_and_file
function from gnome-libs. This uses the right path separator
based on the OS, and also works around a bug in some systems where
a double slash is not allowed.
(default_assembly_name_resolver): Use g_concat_dir_and_file
(mono_assembly_open): ditto.
svn path=/trunk/mono/; revision=508
* Component.cs: Eliminated compile errors by removing redundant fields and
using the ISite member instead. Also raised the Disposed event, but not
sure if it's correct now. Look for FIXME in the comments.
svn path=/trunk/mcs/; revision=504
* mono/tests/stream.cs: new tests for the Stream class
* configure.in: I really need LIBTOOL for libmonowrapper.so, so I
added it again.
* class.h: replaced 'struct MonoMethod' with 'MonoMethod'
* cli.h: removed #include <mono/cli/object.h>
* icall.c: changed everything to support the new calling convention
* hacks.h: added some macros for FreeBSD
* interp.c (get_named_exception): use mono_object_new instead of
newobj, initialize the stack before we call the constructor.
* metadata.c (mono_metadata_signature_equal): impl.
* *: void is now a realy MonoType (instead of using NULL)
* metadata.c (do_mono_metadata_parse_type): use
mono_metadata_parse_type to parse void value.
svn path=/trunk/mono/; revision=502
* parameter.cs (GetParameterInfo): Fix bug where there would be no
method arguments.
* interface.cs (PopulateIndexer): Implemented the code generator
svn path=/trunk/mcs/; revision=496
* x86/x86-codegen.h: fix a couple of buglets and add x86_regp_emit().
Sat Aug 18 12:42:26 CEST 2001 Paolo Molaro <[email protected]>
* class.c, class.h: load also the methods when loading a class.
Sat Aug 18 12:43:38 CEST 2001 Paolo Molaro <[email protected]>
* interp.c, interp.h: added support code to create exceptions.
Changed interncal calling convnetion over to MonoInvocation, to support
exceptions, walking the stack back and forward and passing the 'this'
pointer separately (remove the cludges required before to pass this on the
stack). Use alloca heavily for both local vars and a copy of the incoming
arguments. Init local vars to zero.
Simplify stackval_from_data() and stackval_to_data() to only take a pointer
instead of pointer + offset.
Implement a few exceptions-related opcodes and the code to run finally, fault and
catch blocks as well as a stack trace if no handler is found.
Sat Aug 18 12:51:28 CEST 2001 Paolo Molaro <[email protected]>
* metadata.c, metadata.h: in the signature and method header store
only the space required for holding the loca vars and incoming arguments.
svn path=/trunk/mono/; revision=493
* dump.c, get.c, get.h, main.c: dis_stringify_method_signature()
gets an optional methodef_row index instead of a name, so it
can figure out also the names and attributes of params.
parse_method_signature() and free_method_signature() removed as
they are useless now.
svn path=/trunk/mono/; revision=492
* interface.cs (InterfaceMemberBase): Now we track the new status
here.
(PopulateProperty): Implement property population. Woohoo! Got
Methods and Properties going today.
Removed all the properties for interfaces, and replaced them with
`public readonly' fields.
svn path=/trunk/mcs/; revision=487
* libffi/include/fficonfig.h: Remove as this is auto generated.
* Makefile.am: Only generate libffi.a.
* configure.in: replace A[CM]_PROG_LIBTOOL with AC_PROG_RANLIB.
2001-08-16 Alex Graveley <[email protected]>
* Makefile.am (mono_int_LDADD): Link with ../../libffi/libffi.a
instead of ../../libffi/.libs/libffi.a.
svn path=/trunk/mono/; revision=483
* Added myself as maintainer of System.Attribute which is 95% done.
* Made myself maintainer of System.ConditionalAttribute
svn path=/trunk/mono/; revision=480
* Attribute.cs: implemented all methods except GetHashCode()
* common.src: added Attribute.cs so it would compile in
svn path=/trunk/mcs/; revision=479
* class.cs (MakeConstant): Code to define constants.
* rootcontext.cs (LookupType): New function. Used to locate types
svn path=/trunk/mcs/; revision=469
* common.src: removed UriFormatException.cs because the file is
not there.
* RuntimeTypeHandle.cs: replaced IntrPtr with IntPtr
* Char.cs: replaced byte with char
* Array.cs: make it work with the mono interpreter
svn path=/trunk/mcs/; revision=458
* implemented arrays, but you will need a modified version of
Array.cs to get arrays working (will commit soon)
* interp.c (ves_icall_array_Set): impl.
(ves_icall_array_Get): impl.
(ves_icall_array_ctor): impl.
(ves_icall_System_Array_GetRank): impl.
(ves_icall_System_Array_GetLength): impl.
(ves_icall_System_Array_GetLowerBound): impl.
(mono_lookup_internal_call): impl.
* object.c (mono_new_szarray): impl.
* loader.c (mono_typedef_from_name): return the token, not the index
(mono_get_corlib): impl.
(mono_get_array_class_info): impl.
(method_from_memberref): add array support
(mono_get_method): support INTERNAL_CALL
* class.c (mono_class_create_from_typedef): Array support,
code cleanup, store the token_type, not the token index, added
flag for value types.
(mono_type_to_tydedef): impl.
(mono_class_create_from_typespec): impl.
(mono_array_class_get): impl.
(mono_class_get): support TYPE_SPEC token.
svn path=/trunk/mono/; revision=452
* rootcontext.cs: OH MY! My trick works! It is amazing how nice
this System.Reflection code is. Kudos to Microsoft
* typemanager.cs: Implement a type cache and avoid loading all
types at boot time. Wrap in LookupType the internals. This made
the compiler so much faster. Wow. I rule!
* driver.cs: Make sure we always load mscorlib first (for
debugging purposes, nothing really important).
* Renamespaced things that were on `CSC' to `CIR'. Maybe I should
have moved to `CSC' rather than `CIR'. Oh man! The confussion!
* rootcontext.cs: Lookup types on their namespace; Lookup types
on namespaces that have been imported using the `using' keyword.
svn path=/trunk/mcs/; revision=433
* class.cs (TypeContainer::TypeAttr): Virtualize.
(Class::TypeAttr): Return attributes suitable for this bad boy.
(Struct::TypeAttr): ditto.
Handle nested classes.
(TypeContainer::) Remove all the type visiting code, it is now
replaced with the rootcontext.cs code
* rootcontext.cs (GetClassBases): Added support for structs.
svn path=/trunk/mcs/; revision=429
* interface.cs, statement.cs, class.cs, parameter.cs,
rootcontext.cs, gen-treedump.cs, enum.cs, cs-parse.jay:
Drop use of TypeRefs, and use strings instead.
svn path=/trunk/mcs/; revision=420
* Uri.cs: Initial Implementation. Parsing needs to be fixed to take
into account IPv6 addresses, url encoding needs to be implemented, and
various minor methods need to be written, but this is a decent start.
svn path=/trunk/mcs/; revision=408
* object.h: added MonoArrayObject and MonoStringObject
* loader.c (mono_typedef_from_name):
s/typedef_from_name/(mono_typedef_from_name and made it public.
* class.c (class_compute_field_layout): skip the FIELD signature
(mono_class_create_from_typedef): bug fix: field.last was wrong
(class_compute_field_layout): added some code to make it work for
classes with EXPLICIT_LAYOUT but no offsets specified (I observed
that behaviour on System.Array)
* interp.c (ves_exec_method): impl. NEWARR
(ves_exec_method): impl. most LDELEM/STELEM opcodes, LDLEN
(newarr): impl.
(mono_get_ansi_string): impl.
* mono/tests/pinvoke.cs: we can now print strings ;-)
* mono/tests/array.cs: new test for arrays
svn path=/trunk/mono/; revision=406
* rootcontext.cs:
* class.cs (Struct::Struct): set the SEALED flags after
checking the modifiers.
(TypeContainer::TypeAttr): new property, returns the
TypeAttributes for a class.
* cs-parser.jay (type_list): Oops, list production was creating a
new list of base types.
* rootcontext.cs (StdLib): New property.
(GetInterfaceTypeByName): returns an interface by type name, and
encapsulates error handling here.
(GetInterfaces): simplified.
(ResolveTree): Encapsulated all the tree resolution here.
(CreateClass, GetClassBases, GetInterfaceOrClass): Create class
types.
* driver.cs: Add support for --nostdlib, to avoid loading the
default assemblies.
(Main): Do not put tree resolution here.
* rootcontext.cs: Beginning of the class resolution.
svn path=/trunk/mcs/; revision=404
* metadata.h, metadata.c: add mono_metadata_decode_row_col () to
decode a single column from a row in a metadata table and changes
to take advantage of it in the typedef locator (gives a nice speed up).
Store offset info for function params.
Sat Aug 4 12:36:54 CEST 2001 Paolo Molaro <[email protected]>
* get.c, get.h, main.c, dump.c: implement dis_stringify_method_signature().
More magic constants replaced by enum values (spotted at least 3 real bugs
doing this). Print usage information if an unknown option is given.
Print the full signature when dumping the method table.
Changed method and field table dumps to show the typedef name the field
or method belongs to.
svn path=/trunk/mono/; revision=403
* rootcontext.cs (CloseTypes): Routine to flush types at the end.
(CreateInterface): Track types.
(GetInterfaces): Returns an array of Types from the list of
defined interfaces.
* typemanager.c (AddUserType): Mechanism to track user types (puts
the type on the global type hash, and allows us to close it at the
end).
svn path=/trunk/mcs/; revision=395
* libffi/*: Import libffi CVS version, with minor changes to make it
compile.
* mono/interpreter/Makefile.am: Link against
../../libffi/.libs/libffi.a.
* Makefile.am: Add libffi
* autogen.sh: Replace with adapted gnome autogen.sh
* configure.in: Add AC_CONFIG_SUBDIRS(libffi).
svn path=/trunk/mono/; revision=383
* DateTime.cs: Cleaned up a bit. Added the Add* family members.
Added exceptions. Added IConvertible. Still needs some platform
dependend stuff, the Parse and ToString members
svn path=/trunk/mcs/; revision=382
* tree.cs: Removed RecordType, added RecordClass, RecordStruct and
RecordInterface instead.
* cs-parser.jay: Updated to reflect changes above.
* decl.cs (Definition): Keep track of the TypeBuilder type that
represents this type here. Not sure we will use it in the long
run, but wont hurt for now.
* driver.cs: Smaller changes to accomodate the new code.
Call ResolveInterfaceBases, Call ResolveClassBases, Save assembly
when done.
* rootcontext.cs (CreateInterface): New method, used to create
the System.TypeBuilder type for interfaces.
(ResolveInterfaces): new entry point to resolve the interface
hierarchy.
(CodeGen): Property, used to keep track of the code generator.
svn path=/trunk/mcs/; revision=381
* interp.c (ves_exec_method): found a way to do unordered
compares, implemented CEE_BNE_UN_S, CEE_BGE_UN_S, CEE_BGT_UN_S,
CEE_BLE_UN_S, CEE_BLT_UN_S
* loader.c(mono_map_dll): impl.
(mono_get_method): bug fix: pass index - 1 to fill_pinvoke_info
* mono/tests/pinvoke.cs: impl.
svn path=/trunk/mono/; revision=380
if it is System.String instead of using magic numbers.
* class.c (mono_class_create_from_typedef): do a strcmp to check
if it is System.Object instead of using magic numbers.
* image.h (MONO_IMAGE_IS_CORLIB): removed
svn path=/trunk/mono/; revision=379
* dis-cil.c: properly decode the switch opcode.
Wed Aug 1 22:48:29 CEST 2001 Paolo Molaro <[email protected]>
* class.c, class.h: mono_field_type_size () moved to metadata.
Take correctly into account alignment when laying out
class fields. Fix 5 to 0 magc number (to check for System.Object).
Wed Aug 1 22:54:08 CEST 2001 Paolo Molaro <[email protected]>
* assembly.c: how could mono_assembly_close () had ever worked?
* metadata.c, metadata.h: provide offset info for local vars.
Implement mono_type_size () to take care of alignment as well
as size (it was mono_field_type_size in cli/class.c before).
Wed Aug 1 22:51:38 CEST 2001 Paolo Molaro <[email protected]>
* interp.c: handle also MONO_TYPE_CLASS to/from the stack.
Change locals to be a memory blob, instead of the structured
(but wrong) stackval. Implement bne.un.s opcode. Make the program
exit with the error code from Main().
svn path=/trunk/mono/; revision=369
* assembly.c (mono_assembly_open): set the corlib before we continue.
(mono_assembly_open): replaced strcmp() with !strcmp()
svn path=/trunk/mono/; revision=364
* interp.c (GET_NATI): Switched from using nati_t to cli/types.h
m_i type. Maybe we should rename the types to be m_i_t instead of
m_i alone.
Make the code compile after I broke it.
svn path=/trunk/mono/; revision=361
we override it in SyncStack anyway.
*Stack.cs: Pop() now shrinks the array if we drop below 1/4 full, to
avoid using massive amounts of memory that are not necessary. We only
drop to half the current size, which i hope will avoid the 'ping-pong'
effect.
*Stack.cs: SyncStack.IsReadOnly should return stack.IsReadOnly
instead of just returning false, since we may have a ReadOnly wrapper
in the future (although i can't imagine why). Thanks to David
Menestrina <[email protected]> for pointing this out.
svn path=/trunk/mcs/; revision=350
* metadata.h, metadata.c: decode exception clauses when parsing method header.
Mon Jul 30 20:08:37 CEST 2001 Paolo Molaro <[email protected]>
* dis-cil.c, dis-cil.h, main.c: changes to disassemble also
the information about try/catch/finally blocks.
Mon Jul 30 20:05:23 CEST 2001 Paolo Molaro <[email protected]>
* cli.h, loader.c: usa a char *name field in MonoMethod instead
of the name_idx token.
Mon Jul 30 20:09:58 CEST 2001 Paolo Molaro <[email protected]>
* interp.c: update to use mono_method->name.
svn path=/trunk/mono/; revision=344
2001-07-30 18:17:11 +00:00
746 changed files with 63295 additions and 8052 deletions
something that would help tremendously would be to help with
small duties in the project that need to be addressed.
** To start contributing
To start developing classes or to contribute to the compiler,
you only need Windows and the .NET Beta 2 SDK. Please notice
that you do not need Visual Studio (although you can use it if
you want).
You can get it <a href="http://msdn.microsoft.com/downloads/default.asp?url=/downloads/sample.asp?url=/msdn-files/027/000/976/msdncompositedoc.xml&frame=true">here</a>
Alternatively you can use the <a
href="#compile-service">compilation service</a> that was setup by
Derek.
** Bug reporting
If you find bugs in Mono, please make sure you enter a bug
@@ -40,6 +53,38 @@
packaged up in the official `distribution'
</ul>
<a name="compile-service">
* C# Compilation Service
If you are working on a class for the Mono project, but do not
have a C# compiler available or a Windows machine to run the
.NET SDK, you can use the compilation service that Derek
/// Associates a data source column with a DataSet column, and is implemented by the DataColumnMapping class, which is used in common by .NET data providers.
/// Contains a collection of ColumnMapping objects, and is implemented by the DataColumnMappingCollection, which is used in common by .NET data providers.
/// Allows an object to implement a DataAdapter, and represents a set of methods and mapping action-related properties used to fill and refresh a DataSet and update a data source.
/// Represents a parameter to a Command object, and optionally, its mapping to DataSet columns; and is implemented by .NET data providers that access data sources.
/// Collects all parameters relevant to a Command object and their mappings to DataSet columns, and is implemented by .NET data providers that access data sources.
/// Provides a means of reading one or more forward-only streams of result sets obtained by executing a command at a data source, and is implemented by .NET data providers that access relational databases.
/// Represents a SQL statement that is executed while connected to a data source, and is implemented by .NET data providers that access relational databases.
/// Represents a set of command-related properties that are used to fill the DataSet and update a data source, and is implemented by .NET data providers that access relational databases.
/// Associates a source table with a table in a DataSet, and is implemented by the DataTableMapping class, which is used in common by .NET data providers.
/// Contains a collection of TableMapping objects, and is implemented by the DataTableMappingCollection, which is used in common by .NET data providers.
/// Specifies the type of SQL query to be used by the OleDbRowUpdatedEventArgs, OleDbRowUpdatingEventArgs, SqlRowUpdatedEventArgs, or SqlRowUpdatingEventArgs class.
Loaded 100 of 746 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.