IronRuby in Action一书进入EAP

链接: The IronRuby in Action book went into EAP today
IronRuby in Action在Manning的EAP链接: http://manning.com/carrero

Ivan Porto Carrero的新书, IronRuby in Action,在Manning Early Access Program上已经可以读到一部分。刚才读了其中的第一章。
觉得在很期待这本书的面世的同时,作者的观点可能不完全正确……或者是故意在一开始先以“比较大众”的方式去解释一些概念?
例如说,在1.2.1 Compiled and interpreted languages,
引用
A compiled language in the context of this book is a language that requires a compiler before it can be executed. VB.NET, C# and Java all require a compilation step before they can be executed.
...
An interpreted language means that the code you feed it; gets executed by an interpreter, whose job it is to analyze each statement it encounters and consequently execute the desired action. There is no error checking at compile time because there is no compile time.
...

如果加上“从用户的角度看”这个前提条件的话,上面的叙述是没什么问题,不过作者并没有明确提到这点。一个“解释器”的内部也可以是以“编译器+虚拟机”的形式组织的,只是从用户角度看不到而已……

对这本书最大的疑问是:在IronRuby还远远没有finalize的时候,这书相对最终的IronRuby 1.0.0.0到底能有多准确呢?拭目以待了~

============================================================================

话说现在IronRuby在RubyForge上的SVN repository的版本是revision 110。先前的版本build都没遇到这个问题,这次build的时候发觉出现了好几个错误——主要问题都是出在project property的target设置到了.NET Framework 2.0;那把target设到3.5呢?System.Action跟Microsoft.Scripting.Util.Action就冲突了……好奇怪,IronRuby小组内部的人是怎么build的?
System.Action<T>是.NET Framework 2.0就开始有的,但是 System.ActionSystem.Action<T1,T2>一直到4个参数的版本都是.NET Framework 3.5才出现的,在System.Core里。

Anyway,把冲突的地方都指定为DLR里的Action就没问题了。

我是想关注一下Tomas Matousek在ironruby-core里提到的一句:
引用
Refactors Ruby blocks and procs:
-       The compiled block has now signature (BlockParam, self, formal-args) - self argument was added. Previously it was passed thru BlockParam.Proc in a very hacky way.
-       Removed hacks from dynamic actions on blocks and methods created by define_method. Improved rules generated for these actions.
-       RubyBlockInfo no longer inherits from RubyMemberInfo. There is no reason to do so, blocks are not directly stored in method tables and cannot be invoked via InvokeMemberAction.

Adds YieldAction - a custom Ruby action for yielding to a block that allows to pass BlockParam and self.
Implements module_eval/class_eval - both Proc and string versions.
Implements eval that takes Proc as a binding.
Adds module_eval and proc related unit tests.
...
Yes, they are 1st class. Some of the properties should be accessible, some not. There will be more cleanup later, after all operations are implemented. Some fields might move among classes (RubyBlockInfo, Proc, BlockParam) etc. The id is now 1:1 but might not be in future - some blocks could be compatible if they have the same signature shape.

Tomas

这个YieldAction在\trunk\src\ironruby\Runtime\Calls\YieldAction.cs。不过里面几乎是空的……或许还没实现?

[Ironruby-core] Code Review: zlib
John Lam 写道
non-nullable reference types (that's what the /*!*/ annotations mean).

啊……终于知道代码里的/*!*/是啥意思了。嗯很好……

你可能感兴趣的:(.net,Microsoft,Ruby,vb,VB.NET)