[Ironruby-core] Code Review: AstImprovements2

Tomas Matousek Tomas.Matousek at microsoft.com
Tue Jan 5 19:58:33 EST 2010

  tfpt review "/shelveset:AstImprovements2;REDMOND\tomat"

      Adds ExpressionCollectionBuilder (moves the implementation from IronRuby). This allows to construct optimized expressions via C# initializer syntax. Adds a subclass BlockBuilder that can be used to build blocks like so:
      Expression result = new BlockBuilder {
          (condition) ? foo : null,
      If the expression used in the initializer is null it is skipped.
      If the expression is a sequence of expressions (IEnumerable<Expression>) its content is included in the block.
      BlockBuilder defines an implicit conversion to Expression.
      Tree transformation refactorings:
      -	Replaces some AstFactory utility methods with AstUtils equivalents.
      -	Creates Lambda<T> explicitly to avoid calls to MakeGenericType.
      -	Uses BlockBuilder for building complex blocks.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: AstImprovements2.diff
Type: application/octet-stream
Size: 136018 bytes
Desc: AstImprovements2.diff
URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20100106/1198568f/attachment-0001.obj>

More information about the Ironruby-core mailing list