This is a multi-part message in MIME format.
--------------010206060000040305020509
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Hi,
I've never been able to do a complete 'make install' on the Ruby 1.9
sources because rdoc always throws an exception when processing
ext/yaml/stringio.rb.
I finally figured this out. The problem in is
lib/rdoc/parsers/parse_rb.rb. That file tries to catch NameError (for
undefined constants) with a bare rescue clause. But in Ruby 1.9,
NameError has moved to ScriptError instead of StandardError, so it no
longer gets caught.
The attached patch fixes the problem for me, and I can now successfully
run 'make install'
David
--------------010206060000040305020509
Content-Type: text/plain;
name atch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename atch"
Index: lib/rdoc/parsers/parse_rb.rb
--- lib/rdoc/parsers/parse_rb.rb (revision 13610)
+++ lib/rdoc/parsers/parse_rb.rb (working copy)
@@ -1909,9 +1909,13 @@
container ontainer.find_module_named(name_t.name)
if !container
added_container rue
- obj ame_t.name.split("::").inject(Object) do |state, item|
- state.const_get(item)
- end rescue nil
+ begin
+ obj ame_t.name.split("::").inject(Object) do |state, item|
+ state.const_get(item)
+ end
+ rescue Exception
+ nil # Ignore any exception in the above
+ end
type bj.class Class ? NormalClass : NormalModule
if not [Class, Module].include?(obj.class)
--------------010206060000040305020509--