From: Nobuyoshi Nakada Date: 2009-03-20T09:56:22+09:00 Subject: [ruby-core:22962] Re: [Bug #1302] Strange behavior of callcc Hi, At Thu, 19 Mar 2009 04:33:40 +0900, Christophe Calves wrote in [ruby-core:22933]: > The code runs "[0].map" with a block which uses callcc to > stop the execution of map and return the continuation. Later > this continuation is called three times with three different > values. The expected behavior is that these calls should > result in three different computations. Each computation > being the mapping with the corresponing value. Instead, the > result is very strange. I don't consider it a bug. This is caused by the implementation of Enumerable#map, not callcc. And the difference between callcctest.rb and testcallcc.scm would be resulted in because of the difference between Ruby's Array and Scheme's list. -- Nobu Nakada