* BinaryExpression.cs: Unleash the power of cut and paste.
Bring a bunch of operatros from mcs/expression.cs
* Expression.cs: There is no op_LogicalAnd or op_LogicalOr, I just
used those from mcs, that was wrong. use the proper ones, clean
up the result.
* BinaryExpression.cs: Add method invocations for binary methods.
svn path=/trunk/mcs/; revision=93613
* Expression.cs: There is no op_LogicalAnd or op_LogicalOr, I just
used those from mcs, that was wrong. use the proper ones, clean
up the result.
* BinaryExpression.cs: Add method invocations for binary methods.
svn path=/trunk/mcs/; revision=93605
* BinaryExpression.cs (EmitCoalesce): Add support for emitting
code for Coalesce.
TODO: this does not use the "Conversion" Lambda, which am not sure
who generates this or what it is used for.
(EmitLogical): Fix a couple of bugs in AndAlso, OrElse.
* Expression.cs: Add support for Coalesce.
(BinaryCoreCheck): Move more checking here, instead of the helper
routines, will remove them next.
* LambdaExpression.cs (Compile): Create the delegate last, so we
manage to save the assembly while debugging in case of error
svn path=/trunk/mcs/; revision=93480
* Expression.cs (BinaryCoreCheck): Add checking for a few
operators here (to avoid doing a second pass, handles AndAlso and
OrElse).
(AndAlso, OrElse): Add some code.
* BinaryExpression.cs: Instead of using GetValueOrDefault use
get_Value, as we already probed for the lack of value.
Split out support for And/Or to a separate routine as the code is
not very easy to share with the arithmetics code.
svn path=/trunk/mcs/; revision=93471
* Expression.cs, UnaryExpression.cs, BinaryExpression.cs:
Move the IsUnsigned helper from BinaryExpression to Expression,
so it can be used in UnaryExpression.
svn path=/trunk/mcs/; revision=93387
* Start code generation for nullables, currently this generates
incorrect code for things like:
Expression<Func<int?, int?, int?>> e2 = (a, b) => a + b;
e2.Compile ().Invoke (null, 3))
This should return null, but returns something else.
* Introduce LINQ_DBG env variable, which generates a linq file in
/tmp; It currently does not work as well as it should, as the
Func<> parameters do not mwatch the generated method.
Investigate.
svn path=/trunk/mcs/; revision=93369
Introduce support for Nullable arguments, no code is generated for
these yet, its only tests + node creation behavior at this point.
* Expression.cs (BinaryCoreCheck): Do not allow "int?" and "int"
as operators, they must both be nullable.
NullableTypes in the arguments are transformed into the underlying
values when doing the method validation.
svn path=/trunk/mcs/; revision=93368
* BinaryExpression.cs: Add support for emitting code for some
operators (ported from the Mono C# compiler).
Add tests.
svn path=/trunk/mcs/; revision=93231
* Expression.cs: Bring back the (most) of binary operators. Added
type checking as well and reorganized the source file by topic
instead of alphabetical sorting.
svn path=/trunk/mcs/; revision=92917
* BinaryExpression.cs,
* Expression.cs: revert part of Miguel's last patch.
MakeBinary is expected to call the appropriate factory
methods. Whose methods that are responsible for creating
the good BinaryExpression, wether they use a custom method
or not.
svn path=/trunk/mcs/; revision=92837
* Expression.cs (Constant, MakeBinary and consumers of it): Some
more fill-up changes.
MakeBinary will need much more work to support user-provided
types.
svn path=/trunk/mcs/; revision=92833
* Added Test/ directory, modified Makefile to build and execute
them
* Changed a couple of Expression methods to raise exceptions
identicals to MS ones
* Added tests for AddExpression and ConstantExpression
* Implemented somme missing stuff in BinaryExpression
* The stuff in ExpressionUtils is very generic and does quite some
redundant checks: I started splitting the stuff there into more
"specific" methods that should be both understandable and fast.
I fixed the StringBuilder problem, added unique IDs to all tests,
used Assert.IsNull where appropriate and fixed one more Expression
svn path=/trunk/mcs/; revision=84011