ChangeLog 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607
  1. 2008-05-15 Jb Evain <[email protected]>
  2. * UnaryExpression.cs, EmitContext.cs: emit convert from and
  3. to nullable types.
  4. 2008-05-15 Jb Evain <[email protected]>
  5. * Extensions.cs: add a few useful extensions such as
  6. IsGenericInstanceOf and MakeGenericFrom.
  7. 2008-05-15 Roei Erez <[email protected]>
  8. * ExpressionTransformer.cs: Add a base class for transforming Expressions.
  9. In use at AsQueryable() implementation.
  10. 2008-05-14 Jb Evain <[email protected]>
  11. * EmitContext.cs: only generate a new lambda name if we're in
  12. a debug context.
  13. 2008-05-14 Jb Evain <[email protected]>
  14. * LambdaExpression.cs, EmitContext.cs: When encountering a lambda
  15. inside an ET, compile it as a read of a global. Based on a patch
  16. by Roei Erez <[email protected]>
  17. 2008-05-08 Jb Evain <[email protected]>
  18. * Expression.cs, EmitContext.cs: deal with call to methods
  19. with byref parameters.
  20. 2008-05-07 Roei Erez <[email protected]>
  21. * Add ifdef TARGET_JVM
  22. 2008-05-03 Jb Evain <[email protected]>
  23. * LambdaExpression.cs: move checks to Expression
  24. * Expression.cs: apply check for both typed and untyped lambda
  25. creation, so that the constructor does not throws exception.
  26. Needed to create instances of Expression<> for untyped lambda
  27. factory method. Fixes #386322.
  28. 2008-05-02 Jb Evain <[email protected]>
  29. * Expression.cs: make Emit virtual instead of abstract,
  30. to allow externals libraries to extend Expression.
  31. Patch by Jan Oravec <[email protected]>. Fixes #386097.
  32. 2008-04-29 Jb Evain <[email protected]>
  33. * UnaryExpression.cs (EmitPrimitiveConversion): implement.
  34. 2008-04-28 Jb Evain <[email protected]>
  35. * EmitContext.cs: deal with globals when encountering them while
  36. compiling, and not ahead of time with a dedicated visitor.
  37. 2008-04-27 Jb Evain <[email protected]>
  38. * ConstantExpression.cs (Emit): emit properly null nullable types.
  39. 2008-04-27 Jb Evain <[email protected]>
  40. * Expression.cs: improve method finder.
  41. 2008-04-24 Jb Evain <[email protected]>
  42. * UnaryExpression.cs, EmitContext.cs: implement compilation
  43. of Quote as a global load.
  44. 2008-04-23 Jb Evain <[email protected]>
  45. * UnaryExpression.cs: start implementing EmitConvert.
  46. 2008-04-23 Jb Evain <[email protected]>
  47. * ConstantExpression.cs (Emit): properly Emit null constants.
  48. 2008-04-23 Jb Evain <[email protected]>
  49. * Expression.cs (Constant): check for assignability, not for type
  50. equality, when a type is passed.
  51. 2008-04-23 Jb Evain <[email protected]>
  52. * ExpressionPrinter.cs: ToString convert properly.
  53. 2008-04-22 Jb Evain <[email protected]>
  54. * UnaryExpression.cs: implement IsLiftedToNull properly.
  55. * Expression.cs (Convert, ConvertChecked): implemented computing
  56. of IsLifted and IsLiftedToNull for conversions.
  57. 2008-04-22 Jb Evain <[email protected]>
  58. * Expression.cs (Convert, ConvertChecked): implement.
  59. 2008-04-21 Jb Evain <[email protected]>
  60. * Expression.cs (Call): don't rely on the fact that if the
  61. instance expression is null, then it's a static call. Explicitely
  62. check on the MethodInfo for that.
  63. * EmitContext.cs (EmitCall): same pattern.
  64. 2008-04-20 Jb Evain <[email protected]>
  65. * MemberMemberBinding.cs (Emit): implement.
  66. 2008-04-19 Jb Evain <[email protected]>
  67. * EmitContext.cs: infrastructure work to attach a compiled
  68. lambda expression to an execution scope, and to detect and store
  69. external globals in the scope.
  70. * ConstantExpression.cs: load globals from the scope.
  71. 2008-04-19 Jb Evain <[email protected]>
  72. * ExpressionVisitor.cs (Visit): don't die because of Power.
  73. 2008-04-09 Jb Evain <[email protected]>
  74. * Expression.cs: check for illegal booleab unary expressions.
  75. 2008-04-09 Jb Evain <[email protected]>
  76. * UnaryExpression.cs: implement compilation of negate.
  77. 2008-04-09 Jb Evain <[email protected]>
  78. * UnaryExpression.cs, Expression.cs: implement IsLifted and IsLifted
  79. to null for simple unary operators. Implement Not compilation.
  80. 2008-04-08 Jb Evain <[email protected]>
  81. * ElementInit.cs: emit pop if the add method doesn't return void.
  82. 2008-03-20 Jb Evain <[email protected]>
  83. * Expression.cs: use the new and more complete IsAssignableTo
  84. instead of IsAssignableFrom.
  85. 2008-03-19 Jb Evain <[email protected]>
  86. * LambdaExpression.cs: use the new standardified IsAssignableTo,
  87. fixes ExpressionTest_NewArrayBounds.TestArrayAssignability.
  88. 2008-03-19 Jb Evain <[email protected]>
  89. * Extensions.cs (Type.IsAssignableTo): deal with arrays.
  90. 2008-03-13 Jb Evain <[email protected]>
  91. * NewArrayExpression.cs (EmitNewArrayBounds): implement.
  92. 2008-03-12 Jb Evain <[email protected]>
  93. * NewArrayExpression.cs (Emit): naive implementation of emit support
  94. for array initialization.
  95. 2008-03-11 Jb Evain <[email protected]>
  96. * BinaryExpression.cs: very naive implementation of emitting
  97. array accesses.
  98. 2008-03-11 Jb Evain <[email protected]>
  99. * *.cs: Move the different Emit* helpers to EmitContext,
  100. so that they get used more naturally by the non Expression
  101. types.
  102. 2008-03-10 Jb Evain <[email protected]>
  103. * TypeBinaryExpression.cs, Expression.cs: refactor an EmitIsInst.
  104. * UnaryExpression.cs: implement TypeAs using the EmitIsInst.
  105. 2008-03-10 Jb Evain <[email protected]>
  106. * TypeBinaryExpression.cs (Emit): implement.
  107. 2008-03-08 Jb Evain <[email protected]>
  108. * MemberListBinding.cs (Emit): implement.
  109. * MemberBinding.cs (EmitLoadMember): add helper.
  110. 2008-03-08 Jb Evain <[email protected]>
  111. * MemberAssignment.cs (Emit): implement.
  112. 2008-03-08 Jb Evain <[email protected]>
  113. * ElementInit.cs (Emit): implement.
  114. 2008-03-06 Jb Evain <[email protected]>
  115. * EmitContext.cs: the DebugContext delegate the CreateDelegate
  116. to a DynamicContext to avoid visibility issues in debug mode.
  117. 2008-03-06 Jb Evain <[email protected]>
  118. * EmitContext.cs: Lambda methods bypass JIT visibility checks.
  119. 2008-03-06 Jb Evain <[email protected]>
  120. * MethodCallExpression.cs, Expression.cs: refactor method calling
  121. into a more sophisticated EmitCall in Expression.
  122. * InvocationExpression.cs (Emit): implement using the previous EmitCall.
  123. 2008-03-06 Jb Evain <[email protected]>
  124. * Expression.cs: add a EmitCall helper.
  125. * MemberExpression.cs: implement property access.
  126. 2008-03-06 Jb Evain <[email protected]>
  127. * MethodCallExpression.cs, Expression.cs: refactor a EmitLoad in Expression.
  128. * MemberExpression.cs: use EmitLoad to load the instance field if needed.
  129. 2008-03-06 Jb Evain <[email protected]>
  130. * BinaryExpression.cs, Expression.cs: move EmitStored from
  131. BinaryExpression to Expression.
  132. * MethodCallExpression.cs: allow method calls on structs.
  133. 2008-03-05 Jb Evain <[email protected]>
  134. * Expression.cs: Fix the Call method which takes an array
  135. of type arguments.
  136. 2008-03-05 Jb Evain <[email protected]>
  137. * Expression.cs: fix for a good chunk of lifted/liftToNull tests.
  138. 2008-02-26 Jb Evain <[email protected]>
  139. * Expression.cs (Call): Guess the parameters type from the argument
  140. types if needed.
  141. 2008-02-25 Jb Evain <[email protected]>
  142. * NewExpression.cs (Emit): deal with value types construction.
  143. 2008-02-25 Jb Evain <[email protected]>
  144. * Expression.cs, NewExpression.cs: deal with the fact that value types
  145. don't have a parameterless constructor.
  146. 2008-02-24 Jb Evain <[email protected]>
  147. * LambdaExpression.cs, EmitContext.cs: make compilation
  148. of delegate returning void work.
  149. 2008-02-24 Jb Evain <[email protected]>
  150. * MethodCallExpression.cs: emit call or callvirt depending
  151. on the virtuality of the method.
  152. 2008-02-24 Jb Evain <[email protected]>
  153. * LambdaExpression.cs: properly format error message.
  154. 2008-02-21 Jb Evain <[email protected]>
  155. * BinaryExpression.cs (EmitCoalesce): fix setup_null.
  156. 2008-02-21 Jb Evain <[email protected]>
  157. * BinaryExpression.cs (Emit): fix the both_are_null case.
  158. 2008-02-20 Jb Evain <[email protected]>
  159. * Expression.cs, ExpressionPrinter.cs: implement MemberBind.
  160. 2008-02-20 Jb Evain <[email protected]>
  161. * Expression.cs, ExpressionPrinter.cs: implement ListInit.
  162. 2008-02-19 Jb Evain <[email protected]>
  163. * Expression.cs, ExpressionPrinter.cs: implement MemberInit.
  164. 2008-02-19 Jb Evain <[email protected]>
  165. * Expression.cs, ExpressionPrinter.cs: implement last New
  166. overload for anonymous types.
  167. 2008-02-08 Jb Evain <[email protected]>
  168. * Expression.cs, InvocationExpression.cs, ExpressionPrinter.cs
  169. add support for Invoke.
  170. 2008-02-04 Jb Evain <[email protected]>
  171. * ExpressionPrinter.cs: fix printing of MemberListBinding.
  172. 2008-02-04 Jb Evain <[email protected]>
  173. * Expression.cs, NewExpression.cs: make New(Type) test pass.
  174. 2008-02-04 Jb Evain <[email protected]>
  175. * ExpressionPrinter.cs: fix and clean printing of ElementInit.
  176. 2008-02-02 Jb Evain <[email protected]>
  177. * Expression.cs: fix ListBind(MemberInfo,IEnumerable<ElementInit>).
  178. 2008-02-02 Jb Evain <[email protected]>
  179. * Expression.cs: fix ListBind(MethodInfo,IEnumerable<ElementInit>).
  180. 2008-02-01 Olivier Dufour <[email protected]>
  181. * Expression.cs, ExpressionPrinter.cs:Add ListBind
  182. 2008-02-01 Olivier Dufour <[email protected]>
  183. * Expression.cs, ExpressionPrinter.cs:Add Elementinit
  184. 2008-01-31 Jb Evain <[email protected]>
  185. * UnaryExpression.cs: emit array length.
  186. 2008-01-31 Jb Evain <[email protected]>
  187. * MemberExpression.cs: Simple support for emitting fields.
  188. 2008-01-30 Jb Evain <[email protected]>
  189. * MethodCallExpression.cs: very naive implementation of Emit.
  190. 2008-01-30 Jb Evain <[email protected]>
  191. * NewExpression.cs: add Emit support for reference types.
  192. 2008-01-30 Jb Evain <[email protected]>
  193. * LambdaExpression.cs, EmitContext.cs: small refactoring.
  194. Extract the different EmitContexts to their own file.
  195. 2008-01-29 Jb Evain <[email protected]>
  196. * MethodCallExpression.cs, Expression.cs: complete Calls.
  197. 2008-01-29 Jb Evain <[email protected]>
  198. * Expression.cs, NewExpression.cs, ExpressionPrinter.cs:
  199. implement the first flavors of New.
  200. 2008-01-27 Jb Evain <[email protected]>
  201. * ConditionalExpression.cs: implement Emit.
  202. 2008-01-27 Jb Evain <[email protected]>
  203. * Expression.cs: implement the last Lambda method.
  204. 2008-01-27 Jb Evain <[email protected]>
  205. * LambdaExpression.cs: fix the Type of the LambdaExpressions.
  206. 2008-01-27 Olivier Dufour <[email protected]>
  207. * Expression.cs, InvocationExpession.cs,
  208. ListInitExpression.cs, MemberInitExpression.cs
  209. NewExpression.cs : Add all missing
  210. constructor in Expressions and remove the base one
  211. 2008-01-25 Jb Evain <[email protected]>
  212. * Expression.cs, ExpressionPrinter.cs: implement Bind.
  213. 2008-01-25 Jb Evain <[email protected]>
  214. * MemberMemberBinding.cs, MemberListBinding.cs,
  215. MemberAssignment.cs, MemberBinding.cs:
  216. add constructors.
  217. 2008-01-25 Jb Evain <[email protected]>
  218. * Expression.cs: implement PropertyOrField.
  219. 2008-01-24 Jb Evain <[email protected]>
  220. * Expression.cs, MemberExpression.cs, ExpressionPrinter.cs:
  221. implement Field and Property.
  222. 2008-01-22 Miguel de Icaza <[email protected]>
  223. * BinaryExpression.cs: Unleash the power of cut and paste.
  224. Bring a bunch of operatros from mcs/expression.cs
  225. * Expression.cs: There is no op_LogicalAnd or op_LogicalOr, I just
  226. used those from mcs, that was wrong. use the proper ones, clean
  227. up the result.
  228. * BinaryExpression.cs: Add method invocations for binary methods.
  229. 2008-01-22 Jb Evain <[email protected]>
  230. * Expression.cs, ExpressionPrinter.cs: implement NewArrayList.
  231. 2008-01-22 Jb Evain <[email protected]>
  232. * Expression.cs, ExpressionPrinter.cs, NewArrayExpression.cs:
  233. implement Expression.NewArrayBounds.
  234. 2008-01-22 Jb Evain <[email protected]>
  235. * ExpressionPrinter.cs: fix Lambda and Equal.
  236. 2008-01-22 Miguel de Icaza <[email protected]>
  237. * BinaryExpression.cs (EmitCoalesce): Add support for emitting
  238. code for Coalesce.
  239. TODO: this does not use the "Conversion" Lambda, which am not sure
  240. who generates this or what it is used for.
  241. (EmitLogical): Fix a couple of bugs in AndAlso, OrElse.
  242. * Expression.cs: Add support for Coalesce.
  243. (BinaryCoreCheck): Move more checking here, instead of the helper
  244. routines, will remove them next.
  245. * LambdaExpression.cs (Compile): Create the delegate last, so we
  246. manage to save the assembly while debugging in case of error
  247. 2008-01-21 Miguel de Icaza <[email protected]>
  248. * Expression.cs (BinaryCoreCheck): Add checking for a few
  249. operators here (to avoid doing a second pass, handles AndAlso and
  250. OrElse).
  251. (AndAlso, OrElse): Add some code.
  252. * BinaryExpression.cs: Instead of using GetValueOrDefault use
  253. get_Value, as we already probed for the lack of value.
  254. Split out support for And/Or to a separate routine as the code is
  255. not very easy to share with the arithmetics code.
  256. 2008-01-21 Marek Safar <[email protected]>
  257. * BinaryExpression.cs: Fixed initobj initialization.
  258. 2008-01-21 Jb Evain <[email protected]>
  259. * Expression.cs, UnaryExpression.cs, BinaryExpression.cs:
  260. Move the IsUnsigned helper from BinaryExpression to Expression,
  261. so it can be used in UnaryExpression.
  262. 2008-01-21 Miguel de Icaza <[email protected]>
  263. * Start code generation for nullables, currently this generates
  264. incorrect code for things like:
  265. Expression<Func<int?, int?, int?>> e2 = (a, b) => a + b;
  266. e2.Compile ().Invoke (null, 3))
  267. This should return null, but returns something else.
  268. * Introduce LINQ_DBG env variable, which generates a linq file in
  269. /tmp; It currently does not work as well as it should, as the
  270. Func<> parameters do not mwatch the generated method.
  271. Investigate.
  272. 2008-01-20 Miguel de Icaza <[email protected]>
  273. Introduce support for Nullable arguments, no code is generated for
  274. these yet, its only tests + node creation behavior at this point.
  275. * Expression.cs (BinaryCoreCheck): Do not allow "int?" and "int"
  276. as operators, they must both be nullable.
  277. NullableTypes in the arguments are transformed into the underlying
  278. values when doing the method validation.
  279. 2008-01-18 Miguel de Icaza <[email protected]>
  280. * ParameterExpression.cs: Add emit support.
  281. 2008-01-18 Jb Evain <[email protected]>
  282. * Expression[Printer|Visitor].cs: implement UnaryPlus, Not, Negate.
  283. 2008-01-18 Miguel de Icaza <[email protected]>
  284. * BinaryExpression.cs: Add support for emitting code for some
  285. operators (ported from the Mono C# compiler).
  286. Add tests.
  287. 2008-01-17 Miguel de Icaza <[email protected]>
  288. Beginning of code generation framework for Linq.Expressions.
  289. Some code was borrowed by from the C# compiler
  290. * Expression_T.cs: Fill in the blanks.
  291. * LambdaExpression.cs: Validation of parameters mostly, a tiny bit
  292. of codegen.
  293. * ConstantExpression.cs: Mostly done, need to write tests for
  294. non-fundamental types and other ValueType initializations.
  295. 2008-01-17 Jb Evain <[email protected]>
  296. * Expression.cs: implement MakeMemberAccess.
  297. 2008-01-17 Jb Evain <[email protected]>
  298. * Expression.cs, ExpressionPrinter.cs, BinaryExpression.cs:
  299. implement ArrayIndex.
  300. 2008-01-17 Jb Evain <[email protected]>
  301. * Expression.cs: Use TypeCode for IsInt and IsNumber.
  302. 2008-01-16 Miguel de Icaza <[email protected]>
  303. * Expression.cs: Add support for user-defined operators.
  304. Put back various binary operator tests.
  305. 2008-01-16 Jb Evain <[email protected]>
  306. * Expression.cs, ExpressionPrinter.cs: fix call for static methods.
  307. 2008-01-15 Miguel de Icaza <[email protected]>
  308. * Expression.cs: Do validation on the method parameters and use
  309. the return type if provided.
  310. 2008-01-15 Jb Evain <[email protected]>
  311. * MethodCallExpression.cs, Expression.cs
  312. ExpressionPrinter.cs: Implement Call (Expression, ...)
  313. 2008-01-15 Jb Evain <[email protected]>
  314. * Expression.cs, ConditionalExpressionExpression.cs
  315. ExpressionPrinter.cs : implement Expression.Condition.
  316. 2008-01-15 Jb Evain <[email protected]>
  317. * Expression.cs,
  318. ParameterExpression.cs,
  319. ExpressionPrinter.cs: implement Expression.Parameter
  320. 2008-01-15 Jb Evain <[email protected]>
  321. * ExpressionPrinter.cs (VisitBinaryExpression): simple
  322. implementation (probably misses a few cases).
  323. 2008-01-14 Miguel de Icaza <[email protected]>
  324. * Expression.cs: Bring back the (most) of binary operators. Added
  325. type checking as well and reorganized the source file by topic
  326. instead of alphabetical sorting.
  327. 2008-01-14 Jb Evain <[email protected]>
  328. * ExpressionPrinter.cs: print ArrayLength.
  329. 2008-01-14 Jb Evain <[email protected]>
  330. * Expression.cs: TypeAs can't take value types.
  331. * ExpressionPrinter.cs: implement TypeAs.
  332. 2008-01-14 Jb Evain <[email protected]>
  333. * Expression.cs: implement TypeIs.
  334. * ExpressionPrinter.cs: implement VisitTypeBinaryExpression.
  335. * TypeBinaryExpression.cs: add proper ctor.
  336. 2008-01-14 Jb Evain <[email protected]>
  337. * Expression.cs, ExpressionPrinter.cs: fix for Quote's type.
  338. 2008-01-14 Jb Evain <[email protected]>
  339. * BinaryExpression.cs,
  340. * Expression.cs: revert part of Miguel's last patch.
  341. MakeBinary is expected to call the appropriate factory
  342. methods. Whose methods that are responsible for creating
  343. the good BinaryExpression, wether they use a custom method
  344. or not.
  345. 2008-01-14 Jb Evain <[email protected]>
  346. * Expression.cs: MakeUnary is expected to call the appropriate
  347. factory methods.
  348. 2008-01-14 Miguel de Icaza <[email protected]>
  349. * Expression.cs (Constant, MakeBinary and consumers of it): Some
  350. more fill-up changes.
  351. MakeBinary will need much more work to support user-provided
  352. types.
  353. 2008-01-13 Jb Evain <[email protected]>
  354. * *.cs: fresh implementation.