1 2008-04-19 Jb Evain <jbevain@novell.com>
3 * EmitContext.cs: infrastructure work to attach a compiled
4 lambda expression to an execution scope, and to detect and store
5 external globals in the scope.
6 * ConstantExpression.cs: load globals from the scope.
8 2008-04-19 Jb Evain <jbevain@novell.com>
10 * ExpressionVisitor.cs (Visit): don't die because of Power.
12 2008-04-09 Jb Evain <jbevain@novell.com>
14 * Expression.cs: check for illegal booleab unary expressions.
16 2008-04-09 Jb Evain <jbevain@novell.com>
18 * UnaryExpression.cs: implement compilation of negate.
20 2008-04-09 Jb Evain <jbevain@novell.com>
22 * UnaryExpression.cs, Expression.cs: implement IsLifted and IsLifted
23 to null for simple unary operators. Implement Not compilation.
25 2008-04-08 Jb Evain <jbevain@novell.com>
27 * ElementInit.cs: emit pop if the add method doesn't return void.
29 2008-03-20 Jb Evain <jbevain@novell.com>
31 * Expression.cs: use the new and more complete IsAssignableTo
32 instead of IsAssignableFrom.
34 2008-03-19 Jb Evain <jbevain@novell.com>
36 * LambdaExpression.cs: use the new standardified IsAssignableTo,
37 fixes ExpressionTest_NewArrayBounds.TestArrayAssignability.
39 2008-03-19 Jb Evain <jbevain@novell.com>
41 * Extensions.cs (Type.IsAssignableTo): deal with arrays.
43 2008-03-13 Jb Evain <jbevain@novell.com>
45 * NewArrayExpression.cs (EmitNewArrayBounds): implement.
47 2008-03-12 Jb Evain <jbevain@novell.com>
49 * NewArrayExpression.cs (Emit): naive implementation of emit support
50 for array initialization.
52 2008-03-11 Jb Evain <jbevain@novell.com>
54 * BinaryExpression.cs: very naive implementation of emitting
57 2008-03-11 Jb Evain <jbevain@novell.com>
59 * *.cs: Move the different Emit* helpers to EmitContext,
60 so that they get used more naturally by the non Expression
63 2008-03-10 Jb Evain <jbevain@novell.com>
65 * TypeBinaryExpression.cs, Expression.cs: refactor an EmitIsInst.
66 * UnaryExpression.cs: implement TypeAs using the EmitIsInst.
68 2008-03-10 Jb Evain <jbevain@novell.com>
70 * TypeBinaryExpression.cs (Emit): implement.
72 2008-03-08 Jb Evain <jbevain@novell.com>
74 * MemberListBinding.cs (Emit): implement.
75 * MemberBinding.cs (EmitLoadMember): add helper.
77 2008-03-08 Jb Evain <jbevain@novell.com>
79 * MemberAssignment.cs (Emit): implement.
81 2008-03-08 Jb Evain <jbevain@novell.com>
83 * ElementInit.cs (Emit): implement.
85 2008-03-06 Jb Evain <jbevain@novell.com>
87 * EmitContext.cs: the DebugContext delegate the CreateDelegate
88 to a DynamicContext to avoid visibility issues in debug mode.
90 2008-03-06 Jb Evain <jbevain@novell.com>
92 * EmitContext.cs: Lambda methods bypass JIT visibility checks.
94 2008-03-06 Jb Evain <jbevain@novell.com>
96 * MethodCallExpression.cs, Expression.cs: refactor method calling
97 into a more sophisticated EmitCall in Expression.
98 * InvocationExpression.cs (Emit): implement using the previous EmitCall.
100 2008-03-06 Jb Evain <jbevain@novell.com>
102 * Expression.cs: add a EmitCall helper.
103 * MemberExpression.cs: implement property access.
105 2008-03-06 Jb Evain <jbevain@novell.com>
107 * MethodCallExpression.cs, Expression.cs: refactor a EmitLoad in Expression.
108 * MemberExpression.cs: use EmitLoad to load the instance field if needed.
110 2008-03-06 Jb Evain <jbevain@novell.com>
112 * BinaryExpression.cs, Expression.cs: move EmitStored from
113 BinaryExpression to Expression.
114 * MethodCallExpression.cs: allow method calls on structs.
116 2008-03-05 Jb Evain <jbevain@novell.com>
118 * Expression.cs: Fix the Call method which takes an array
121 2008-03-05 Jb Evain <jbevain@novell.com>
123 * Expression.cs: fix for a good chunk of lifted/liftToNull tests.
125 2008-02-26 Jb Evain <jbevain@novell.com>
127 * Expression.cs (Call): Guess the parameters type from the argument
130 2008-02-25 Jb Evain <jbevain@novell.com>
132 * NewExpression.cs (Emit): deal with value types construction.
134 2008-02-25 Jb Evain <jbevain@novell.com>
136 * Expression.cs, NewExpression.cs: deal with the fact that value types
137 don't have a parameterless constructor.
139 2008-02-24 Jb Evain <jbevain@novell.com>
141 * LambdaExpression.cs, EmitContext.cs: make compilation
142 of delegate returning void work.
144 2008-02-24 Jb Evain <jbevain@novell.com>
146 * MethodCallExpression.cs: emit call or callvirt depending
147 on the virtuality of the method.
149 2008-02-24 Jb Evain <jbevain@novell.com>
151 * LambdaExpression.cs: properly format error message.
153 2008-02-21 Jb Evain <jbevain@novell.com>
155 * BinaryExpression.cs (EmitCoalesce): fix setup_null.
157 2008-02-21 Jb Evain <jbevain@novell.com>
159 * BinaryExpression.cs (Emit): fix the both_are_null case.
161 2008-02-20 Jb Evain <jbevain@novell.com>
163 * Expression.cs, ExpressionPrinter.cs: implement MemberBind.
165 2008-02-20 Jb Evain <jbevain@novell.com>
167 * Expression.cs, ExpressionPrinter.cs: implement ListInit.
169 2008-02-19 Jb Evain <jbevain@novell.com>
171 * Expression.cs, ExpressionPrinter.cs: implement MemberInit.
173 2008-02-19 Jb Evain <jbevain@novell.com>
175 * Expression.cs, ExpressionPrinter.cs: implement last New
176 overload for anonymous types.
178 2008-02-08 Jb Evain <jbevain@novell.com>
180 * Expression.cs, InvocationExpression.cs, ExpressionPrinter.cs
181 add support for Invoke.
183 2008-02-04 Jb Evain <jbevain@novell.com>
185 * ExpressionPrinter.cs: fix printing of MemberListBinding.
187 2008-02-04 Jb Evain <jbevain@novell.com>
189 * Expression.cs, NewExpression.cs: make New(Type) test pass.
191 2008-02-04 Jb Evain <jbevain@novell.com>
193 * ExpressionPrinter.cs: fix and clean printing of ElementInit.
195 2008-02-02 Jb Evain <jbevain@novell.com>
197 * Expression.cs: fix ListBind(MemberInfo,IEnumerable<ElementInit>).
199 2008-02-02 Jb Evain <jbevain@novell.com>
201 * Expression.cs: fix ListBind(MethodInfo,IEnumerable<ElementInit>).
203 2008-02-01 Olivier Dufour <olivier.duff@gmail.com>
205 * Expression.cs, ExpressionPrinter.cs:Add ListBind
207 2008-02-01 Olivier Dufour <olivier.duff@gmail.com>
209 * Expression.cs, ExpressionPrinter.cs:Add Elementinit
211 2008-01-31 Jb Evain <jbevain@novell.com>
213 * UnaryExpression.cs: emit array length.
215 2008-01-31 Jb Evain <jbevain@novell.com>
217 * MemberExpression.cs: Simple support for emitting fields.
219 2008-01-30 Jb Evain <jbevain@novell.com>
221 * MethodCallExpression.cs: very naive implementation of Emit.
223 2008-01-30 Jb Evain <jbevain@novell.com>
225 * NewExpression.cs: add Emit support for reference types.
227 2008-01-30 Jb Evain <jbevain@novell.com>
229 * LambdaExpression.cs, EmitContext.cs: small refactoring.
230 Extract the different EmitContexts to their own file.
232 2008-01-29 Jb Evain <jbevain@novell.com>
234 * MethodCallExpression.cs, Expression.cs: complete Calls.
236 2008-01-29 Jb Evain <jbevain@novell.com>
238 * Expression.cs, NewExpression.cs, ExpressionPrinter.cs:
239 implement the first flavors of New.
241 2008-01-27 Jb Evain <jbevain@novell.com>
243 * ConditionalExpression.cs: implement Emit.
245 2008-01-27 Jb Evain <jbevain@novell.com>
247 * Expression.cs: implement the last Lambda method.
249 2008-01-27 Jb Evain <jbevain@novell.com>
251 * LambdaExpression.cs: fix the Type of the LambdaExpressions.
253 2008-01-27 Olivier Dufour <olivier.duff@gmail.com>
255 * Expression.cs, InvocationExpession.cs,
256 ListInitExpression.cs, MemberInitExpression.cs
257 NewExpression.cs : Add all missing
258 constructor in Expressions and remove the base one
260 2008-01-25 Jb Evain <jbevain@novell.com>
262 * Expression.cs, ExpressionPrinter.cs: implement Bind.
264 2008-01-25 Jb Evain <jbevain@novell.com>
266 * MemberMemberBinding.cs, MemberListBinding.cs,
267 MemberAssignment.cs, MemberBinding.cs:
270 2008-01-25 Jb Evain <jbevain@novell.com>
272 * Expression.cs: implement PropertyOrField.
274 2008-01-24 Jb Evain <jbevain@novell.com>
276 * Expression.cs, MemberExpression.cs, ExpressionPrinter.cs:
277 implement Field and Property.
279 2008-01-22 Miguel de Icaza <miguel@novell.com>
281 * BinaryExpression.cs: Unleash the power of cut and paste.
283 Bring a bunch of operatros from mcs/expression.cs
285 * Expression.cs: There is no op_LogicalAnd or op_LogicalOr, I just
286 used those from mcs, that was wrong. use the proper ones, clean
289 * BinaryExpression.cs: Add method invocations for binary methods.
291 2008-01-22 Jb Evain <jbevain@novell.com>
293 * Expression.cs, ExpressionPrinter.cs: implement NewArrayList.
295 2008-01-22 Jb Evain <jbevain@novell.com>
297 * Expression.cs, ExpressionPrinter.cs, NewArrayExpression.cs:
298 implement Expression.NewArrayBounds.
300 2008-01-22 Jb Evain <jbevain@novell.com>
302 * ExpressionPrinter.cs: fix Lambda and Equal.
304 2008-01-22 Miguel de Icaza <miguel@novell.com>
306 * BinaryExpression.cs (EmitCoalesce): Add support for emitting
309 TODO: this does not use the "Conversion" Lambda, which am not sure
310 who generates this or what it is used for.
312 (EmitLogical): Fix a couple of bugs in AndAlso, OrElse.
314 * Expression.cs: Add support for Coalesce.
315 (BinaryCoreCheck): Move more checking here, instead of the helper
316 routines, will remove them next.
318 * LambdaExpression.cs (Compile): Create the delegate last, so we
319 manage to save the assembly while debugging in case of error
321 2008-01-21 Miguel de Icaza <miguel@novell.com>
323 * Expression.cs (BinaryCoreCheck): Add checking for a few
324 operators here (to avoid doing a second pass, handles AndAlso and
327 (AndAlso, OrElse): Add some code.
329 * BinaryExpression.cs: Instead of using GetValueOrDefault use
330 get_Value, as we already probed for the lack of value.
332 Split out support for And/Or to a separate routine as the code is
333 not very easy to share with the arithmetics code.
335 2008-01-21 Marek Safar <marek.safar@gmail.com>
337 * BinaryExpression.cs: Fixed initobj initialization.
339 2008-01-21 Jb Evain <jbevain@novell.com>
341 * Expression.cs, UnaryExpression.cs, BinaryExpression.cs:
342 Move the IsUnsigned helper from BinaryExpression to Expression,
343 so it can be used in UnaryExpression.
345 2008-01-21 Miguel de Icaza <miguel@novell.com>
347 * Start code generation for nullables, currently this generates
348 incorrect code for things like:
350 Expression<Func<int?, int?, int?>> e2 = (a, b) => a + b;
351 e2.Compile ().Invoke (null, 3))
353 This should return null, but returns something else.
355 * Introduce LINQ_DBG env variable, which generates a linq file in
356 /tmp; It currently does not work as well as it should, as the
357 Func<> parameters do not mwatch the generated method.
361 2008-01-20 Miguel de Icaza <miguel@novell.com>
363 Introduce support for Nullable arguments, no code is generated for
364 these yet, its only tests + node creation behavior at this point.
366 * Expression.cs (BinaryCoreCheck): Do not allow "int?" and "int"
367 as operators, they must both be nullable.
369 NullableTypes in the arguments are transformed into the underlying
370 values when doing the method validation.
372 2008-01-18 Miguel de Icaza <miguel@novell.com>
374 * ParameterExpression.cs: Add emit support.
376 2008-01-18 Jb Evain <jbevain@novell.com>
378 * Expression[Printer|Visitor].cs: implement UnaryPlus, Not, Negate.
380 2008-01-18 Miguel de Icaza <miguel@novell.com>
382 * BinaryExpression.cs: Add support for emitting code for some
383 operators (ported from the Mono C# compiler).
387 2008-01-17 Miguel de Icaza <miguel@novell.com>
389 Beginning of code generation framework for Linq.Expressions.
390 Some code was borrowed by from the C# compiler
392 * Expression_T.cs: Fill in the blanks.
394 * LambdaExpression.cs: Validation of parameters mostly, a tiny bit
397 * ConstantExpression.cs: Mostly done, need to write tests for
398 non-fundamental types and other ValueType initializations.
400 2008-01-17 Jb Evain <jbevain@novell.com>
402 * Expression.cs: implement MakeMemberAccess.
404 2008-01-17 Jb Evain <jbevain@novell.com>
406 * Expression.cs, ExpressionPrinter.cs, BinaryExpression.cs:
407 implement ArrayIndex.
409 2008-01-17 Jb Evain <jbevain@novell.com>
411 * Expression.cs: Use TypeCode for IsInt and IsNumber.
413 2008-01-16 Miguel de Icaza <miguel@novell.com>
415 * Expression.cs: Add support for user-defined operators.
417 Put back various binary operator tests.
419 2008-01-16 Jb Evain <jbevain@novell.com>
421 * Expression.cs, ExpressionPrinter.cs: fix call for static methods.
423 2008-01-15 Miguel de Icaza <miguel@novell.com>
425 * Expression.cs: Do validation on the method parameters and use
426 the return type if provided.
428 2008-01-15 Jb Evain <jbevain@novell.com>
430 * MethodCallExpression.cs, Expression.cs
431 ExpressionPrinter.cs: Implement Call (Expression, ...)
433 2008-01-15 Jb Evain <jbevain@novell.com>
435 * Expression.cs, ConditionalExpressionExpression.cs
436 ExpressionPrinter.cs : implement Expression.Condition.
438 2008-01-15 Jb Evain <jbevain@novell.com>
441 ParameterExpression.cs,
442 ExpressionPrinter.cs: implement Expression.Parameter
444 2008-01-15 Jb Evain <jbevain@novell.com>
446 * ExpressionPrinter.cs (VisitBinaryExpression): simple
447 implementation (probably misses a few cases).
449 2008-01-14 Miguel de Icaza <miguel@novell.com>
451 * Expression.cs: Bring back the (most) of binary operators. Added
452 type checking as well and reorganized the source file by topic
453 instead of alphabetical sorting.
455 2008-01-14 Jb Evain <jbevain@novell.com>
457 * ExpressionPrinter.cs: print ArrayLength.
459 2008-01-14 Jb Evain <jbevain@novell.com>
461 * Expression.cs: TypeAs can't take value types.
462 * ExpressionPrinter.cs: implement TypeAs.
464 2008-01-14 Jb Evain <jbevain@novell.com>
466 * Expression.cs: implement TypeIs.
467 * ExpressionPrinter.cs: implement VisitTypeBinaryExpression.
468 * TypeBinaryExpression.cs: add proper ctor.
470 2008-01-14 Jb Evain <jbevain@novell.com>
472 * Expression.cs, ExpressionPrinter.cs: fix for Quote's type.
474 2008-01-14 Jb Evain <jbevain@novell.com>
476 * BinaryExpression.cs,
477 * Expression.cs: revert part of Miguel's last patch.
478 MakeBinary is expected to call the appropriate factory
479 methods. Whose methods that are responsible for creating
480 the good BinaryExpression, wether they use a custom method
483 2008-01-14 Jb Evain <jbevain@novell.com>
485 * Expression.cs: MakeUnary is expected to call the appropriate
488 2008-01-14 Miguel de Icaza <miguel@novell.com>
490 * Expression.cs (Constant, MakeBinary and consumers of it): Some
491 more fill-up changes.
493 MakeBinary will need much more work to support user-provided
496 2008-01-13 Jb Evain <jbevain@novell.com>
498 * *.cs: fresh implementation.