[#6363] Re: rescue clause affecting IO loop behavior — ts <decoux@...>

>>>>> "D" == David Alan Black <dblack@candle.superlink.net> writes:

17 messages 2000/11/14
[#6367] Re: rescue clause affecting IO loop behavior — David Alan Black <dblack@...> 2000/11/14

Hello again --

[#6582] best way to interleaf arrays? — David Alan Black <dblack@...>

Hello --

15 messages 2000/11/26

[#6646] RE: Array Intersect (&) question — Aleksi Niemel<aleksi.niemela@...>

Ross asked something about widely known and largely ignored language (on

23 messages 2000/11/29
[#6652] RE: Array Intersect (&) question — rpmohn@... (Ross Mohn) 2000/11/29

aleksi.niemela@cinnober.com (Aleksi Niemel) wrote in

[#6723] Re: Array Intersect (&) question — Mathieu Bouchard <matju@...> 2000/12/01

> >Use a hash. Here's code to do both and more. It assumes that

[#6656] printing/accessing arrays and hashes — raja@... (Raja S.)

I'm coming to Ruby with a Python & Common Lisp background.

24 messages 2000/11/30

[ruby-talk:6211] Re: marshal.dump again

From: Hugh Sasse Staff Elec Eng <hgs@...>
Date: 2000-11-09 14:32:33 UTC
List: ruby-talk #6211
On Thu, 9 Nov 2000, ts wrote:

> >>>>> "H" == Hugh Sasse Staff Elec Eng <hgs@dmu.ac.uk> writes:
> 
> H> But how does it work?  Does it use 'type' to find this, or is there
> H> some language feature I should be aware of that I'm not.
> 
	[...]
>     else if (argc == 2) {
> 	if (FIXNUM_P(a1)) limit = FIX2INT(a1);
> 	else port = a1;
>     }
> 

sort of using type then. Ok. thanks.

> #define FIXNUM_P(f) (((long)(f))&FIXNUM_FLAG)
> #define FIXNUM_FLAG 0x01
> 
[on limit argument default value]
> H> Hmmm, The Book says its 100.

page 432, about half way down. pp272-4 doesn't really talk about
depth much; if -1 dumps everthing, then maybe there's no need.

> 
>  marshal.c (ruby-1.6.1)
> 
> [..]
>     if (limit == 0) {
> 	rb_raise(rb_eArgError, "exceed depth limit");
>     }
> [...]
>     else {
> 	long num;
> 
> 	limit--;
> [...]
> static VALUE
> marshal_dump(argc, argv)
>     int argc;
>     VALUE* argv;
> {
>     VALUE obj, port, a1, a2;
>     int limit = -1;
> [...]
>  

OK. I'll CC this to rubybook, so they have the info where they want it.
> 
> 
> Guy Decoux
> 
> 
	Thank you.
	Hugh
	hgs@dmu.ac.uk


In This Thread