{"id":340,"date":"2003-03-31T21:37:41","date_gmt":"2003-04-01T02:37:41","guid":{"rendered":"\/?p=340"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-30T04:00:00","slug":"continuations_and_vms","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2003\/03\/31\/continuations_and_vms\/","title":{"rendered":"Continuations and VMs"},"content":{"rendered":"<p>\n\n<a href=\"http:\/\/www.sidhe.org\/~dan\/blog\/archives\/000156.html\">Dan Sugalski<\/a>:\n\n<\/p>\n\n\n\n<blockquote cite=\"http:\/\/www.sidhe.org\/~dan\/blog\/archives\/000156.html\">\n\nAnyway, a continuation is essentially a closure that, in addition to closing over the lexical environment, also closes over the control chain. (Well, OK, control stack, but if you&rsquo;re doing continuations odds are it&rsquo;s a singly linked list rather than a real stack.) CS texts generally go on about continuations being &ldquo;the rest of the program&rdquo; or &ldquo;gotos with arguments&rdquo; or suchlike stuff. If those float your boat, great&mdash;they never made sense to me.\n\n<\/blockquote>\n\n\n\n<p>\n\nYeah, I think it depends on whether you are looking at this from the angle of implementation or theory. If you&rsquo;re writing a VM, then you think in terms of closing over the control chain. If you&rsquo;re doing denotational semantics, you think in terms of lambdas for the rest of the program.\n\n<\/p>\n\n\n\n<p>\n\nUpdate: Here&rsquo;s <a href=\"http:\/\/www.sidhe.org\/~dan\/blog\/archives\/000157.html\">part 2<\/a>.\n\n<\/p>","protected":false},"excerpt":{"rendered":"<p>Dan Sugalski: Anyway, a continuation is essentially a closure that, in addition to closing over the lexical environment, also closes over the control chain. (Well, OK, control stack, but if you&rsquo;re doing continuations odds are it&rsquo;s a singly linked list rather than a real stack.) CS texts generally go on about continuations being &ldquo;the rest [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"","apple_news_api_id":"","apple_news_api_modified_at":"","apple_news_api_revision":"","apple_news_api_share_url":"","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[4],"tags":[],"class_list":["post-340","post","type-post","status-publish","format-standard","hentry","category-programming-category"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/340","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=340"}],"version-history":[{"count":0,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/340\/revisions"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=340"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=340"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=340"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}