随笔 - 130,  文章 - 0,  评论 - 282,  阅读 - 23万
02 2014 档案
4.5你太黑了,不带这么玩TypeForwardedTo的
摘要:话说最近好不容易把framework 4.0的metadata信息都能全部抽出了,结果换4.5挂了。。。framework那帮人在4.5里面用了些什么诡异的玩意?结果一看4.5的部分field用了typed function pointer这个诡异的类型,好吧,还好之前留好空挡了,就等有空的时候去填空,现在就乖乖的补上实现,最多麻烦点,field signature里面放个类型,类型里面可以选typed function pointer,typed function pointer里面有个method signature,method signature里面继续有类型,当然类型里面要是他们高兴 阅读全文
posted @ 2014-02-25 22:43 Zhenway 阅读(734) 评论(0) 推荐(0) 编辑
一个非常简单的反射加速方案
摘要:不废话,直接上代码: class Program { private static readonly MethodInfo HelpMethod = typeof(Program).GetMethod("GetHelp", BindingFlags.NonPublic | BindingFlags.Static); static void Main(string[] args) { // you can cache the delegate, the type of delegate is always Func ... 阅读全文
posted @ 2014-02-24 16:33 Zhenway 阅读(452) 评论(2) 推荐(0) 编辑

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

点击右上角即可分享
微信分享提示