饭后温柔

汉堡与老干妈同嚼 有可乐味
  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2013年8月8日

摘要: coroutine: stackless和stackful jmp 基于switch的trick: http://www.chiark.greenend.org.uk/~sgtatham/coroutines.html 文中提到高德纳另有一套办法. #define crBegin static int state=0; switch(state) { case 0:#define crReturn(x) do { state=__LINE__; return x; \ case __LINE__:; } while (0)#defin... 阅读全文

posted @ 2013-08-08 11:50 饭后温柔 阅读(374) 评论(0) 推荐(0)