[#3479] Missing .document files for ext/ libraries — Brian Candler <B.Candler@...>

The ri documentation for zlib, strscan and iconv doesn't get built by 'make

12 messages 2004/10/06

[#3492] Re: ANN: Free-form-operators patch — Markus <markus@...>

> In message "Re: ANN: Free-form-operators patch"

15 messages 2004/10/11
[#3493] Re: ANN: Free-form-operators patch — Yukihiro Matsumoto <matz@...> 2004/10/11

Hi,

[#3495] Re: ANN: Free-form-operators patch — Markus <markus@...> 2004/10/12

On Mon, 2004-10-11 at 16:16, Yukihiro Matsumoto wrote:

[#3561] 1.8.2 - what can we do to help? — Dave Thomas <dave@...>

Folks:

23 messages 2004/10/26
[#3562] Re: 1.8.2 - what can we do to help? — Yukihiro Matsumoto <matz@...> 2004/10/27

Hi,

Re: [BUG] autoload

From: Joel VanderWerf <vjoel@...>
Date: 2004-10-31 18:21:54 UTC
List: ruby-core #3667
ts wrote:
>>>>>>"J" == Joel VanderWerf <vjoel@PATH.Berkeley.EDU> writes:
> 
> 
> J> Something has changed in 1.9 snapshots in the last week that is breaking 
> J> my autoloads.
> 
>  This is this [ruby-list:40085]

The issue seems to be whether or not foo.rb should be added to $" before 
loading the file. As of 2004-10-29, the stable snapshot says yes, but 
the 1.9 snapshot says no:

$ cat f1.rb
require 'f2'
p $"

$ cat f2.rb
p $"

$ ruby-snapshot -v f1.rb
ruby 1.9.0 (2004-10-29) [i686-linux]
[]
["f2.rb"]

$ ruby-stable-snapshot -v f1.rb
ruby 1.8.2 (2004-10-29) [i686-linux]
["f2.rb"]
["f2.rb"]

The reason for this change seems to be in case an exception happens in 
the required file, and then the calling code detects the exception and 
tries to require it again. This makes sense.

It's interesting that circular requires are still handled correctly 
without using $". There is loading_tbl variable in eval.c that keeps 
track of what all threads are trying to load. Only when a load is 
finished does the feature name get pushed onto $".

Antoher interesting point: rb_autoload_load() first calls 
autoload_delete(), which is the source of my problem. The :Bug2=>"bug1" 
entry is being deleted, but the :Bug1=>"bug1" entry is not. So when 
"class Bug1; end" is found at the top of bug1.rb, ruby tries to autoload 
"bug1.rb", but sees that this file is already in the loading_tbl, and 
does not load it. Thus the undefined constant.

So maybe rb_autoload_load() should delete _all_ entries that refer to 
the same file name as the one currently being autoloaded?

In This Thread