[#600] A `File' is not a `IO'????? — clemens.hintze@...

17 messages 1999/08/10
[#602] Re: A `File' is not a `IO'????? — matz@... (Yukihiro Matsumoto) 1999/08/10

Hi,

[#679] Documentation about RD? — Clemens Hintze <c.hintze@...>

Hi,

78 messages 1999/08/17
[#680] Summary of discussion about RD (Re: Documentation about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/18

=begin

[#683] Re: Summary of discussion about RD (Re: Documenta tion about RD?) — clemens.hintze@... 1999/08/18

On 18 Aug, Toshiro Kuwabara wrote:

[#686] Re: Summary of discussion about RD (Re: Documenta tion about RD?) — gotoken@... (GOTO Kentaro) 1999/08/18

Hi,

[#687] Re: Summary of discussion about RD (Re: Docum enta tion about RD?) — clemens.hintze@... 1999/08/18

On 18 Aug, GOTO Kentaro wrote:

[#693] Re: Summary of discussion about RD (Re: Docum enta tion about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/18

Hi,

[#695] Re: Summary of discussion about RD (Re: Docum enta tion about RD?) — Clemens Hintze <c.hintze@...> 1999/08/18

On 19 Aug, Toshiro Kuwabara wrote:

[#697] Re: Summary of discussion about RD (Re: Docum enta tion about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/19

Hi,

[#703] Re: Summary of discussion about RD (Re: Docum enta tion about RD?) — Clemens Hintze <c.hintze@...> 1999/08/19

On 19 Aug, Toshiro Kuwabara wrote:

[#706] Re: Summary of discussion about RD (Re: Docum enta tion about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/19

Hi,

[#681] Re: Summary of discussion about RD (Re: Documentation about RD?) — gotoken@... (GOTO Kentaro) 1999/08/18

Hi,

[#682] Re: Summary of discussion about RD (Re: Documentation about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/18

Hi,

[#684] Re: Summary of discussion about RD (Re: Documentation about RD?) — TAKAHASHI Masayoshi <maki@...> 1999/08/18

Hi Tosh and all,

[#685] Re: Summary of discussion about RD (Re: Documentation about RD?) — gotoken@... (GOTO Kentaro) 1999/08/18

Hi,

[#689] Re: Summary of discussion about RD (Re: Documentation about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/18

Hi,

[#694] Re: Summary of discussion about RD (Re: Documentation about RD?) — matz@... (Yukihiro Matsumoto) 1999/08/18

Hi,

[#700] Re: Summary of discussion about RD (Re: Documentation about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/19

Hi,

[#702] Re: Summary of discussion about RD (Re: Documentation about RD?) — matz@... (Yukihiro Matsumoto) 1999/08/19

Hi,

[#704] Re: Summary of discussion about RD (Re: Docum entation about RD?) — Clemens Hintze <c.hintze@...> 1999/08/19

On 19 Aug, Yukihiro Matsumoto wrote:

[#719] Re: Summary of discussion about RD (Re: Docum entation about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/20

Hi,

[#720] Re: Summary of discussion about RD (Re: Docum entation about RD?) — clemens.hintze@... 1999/08/20

On 20 Aug, Toshiro Kuwabara wrote:

[#721] Re: Summary of discussion about RD (Re: Docum entation about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/20

Hi,

[#722] Re: Summary of discussion about RD (Re: Docum entation about RD?) — clemens.hintze@... 1999/08/20

On 21 Aug, Toshiro Kuwabara wrote:

[#723] Re: Summary of discussion about RD (Re: Docum entation about RD?) — Toshiro Kuwabara <toshirok@...3.so-net.ne.jp> 1999/08/20

Hi,

[#737] RD with multi charset — Minero Aoki <aamine@...>

Hi, I'm Minero Aoki. This is my first mail in this mailling list.

26 messages 1999/08/22

[ruby-talk:00673] Re: How do I use `callcc'

From: clemens.hintze@...
Date: 1999-08-17 14:46:48 UTC
List: ruby-talk #673
On 17 Aug, Yukihiro Matsumoto wrote:
> Hi,
> 
> In message "[ruby-talk:00667] How do I use `callcc'"
>     on 99/08/15, Clemens Hintze <c.hintze@gmx.net> writes:
> 

[...]

> 
> Continuations are say dynamic labels;  you can't alter them.  But
> using it, you can emulate coroutines.  Here's something similar.

[...]

Thanks for the example. Now some things are a lot more clear to me! :-)

> 
> By the way, why don't you use thread, instead of emulating coroutine
> by yourself.

Sometimes a coroutine can be of more use than a thread. With coroutines
I can emulate threading with an own scheduler adapted to my needs. So
perhaps Ruby could also have threading even on MSDOS? ;-)))

Furthermore I have not pay too much attention to synchronize issues
with coroutines... Often coroutines are better for RT tasks than
threads, etc. pp. :-)

> 
> |I have thougth, the execution would go back till after (1), so that the
> |calculation will be performed, and then the result would be returned.
> |But it seems also to influence the global execution. Because it goes
> |not only back to (1) but back to (2).
> 
> As I said before continuations are labels.  calling Continuation#call
> jumps into the place where the continuation created.

I have understood that! But not with all consequences. The surprising
fact for me was, that this `dynamic label' would also influence the
state of the level that called the method, that use `callcc 

	def crea_cont
	   callcc {|c| return c}     # 1
	   1
	end

	f = crea_cont                # 2
	p f
=> #<Continuation:0x3b738>
	f.call
        p f
=> 1

That means `f.call' was returning to (#1) but after leaving of method
`crea_cont' I was suddenly on (#2), so that `f' was reassigned. That
has astonished me. :-)))))
	

> 
>                                                         matz.

\cle

In This Thread