summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorryan <ryan@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-04-26 17:06:54 +0000
committerryan <ryan@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-04-26 17:06:54 +0000
commitdda452747887037dc5f1969b3f23403bb592c084 (patch)
tree95d7d2b5105f2001a491ef87793af48d86f5ee2d
parenta2492c4956de20e16be482bc9555e7a90f60d416 (diff)
Fixed raise Interrupt and Module rdoc
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@12226 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog7
-rw-r--r--lib/yaml/tag.rb7
-rw-r--r--signal.c17
3 files changed, 20 insertions, 11 deletions
diff --git a/ChangeLog b/ChangeLog
index a1d7e660c0..2da62025fe 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+Fri Apr 27 02:00:17 2007 Ryan Davis <ryand-ruby@zenspider.com>
+
+ * signal.c: Fixed backwards compatibility for 'raise Interrupt'.
+
+ * lib/yaml/tag.rb: Running rdoc over the 1.8.6 tree skips
+ Module. Patch from James Britt
+
Thu Apr 26 13:54:51 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
* misc/ruby-style.el: new file. C/C++ style for ruby source code.
diff --git a/lib/yaml/tag.rb b/lib/yaml/tag.rb
index 0fb6bef9a0..56c3513bc0 100644
--- a/lib/yaml/tag.rb
+++ b/lib/yaml/tag.rb
@@ -51,12 +51,11 @@ module YAML
end
class Module
- # :stopdoc:
# Adds a taguri _tag_ to a class, used when dumping or loading the class
# in YAML. See YAML::tag_class for detailed information on typing and
# taguris.
- def yaml_as( tag, sc = true )
+ def yaml_as( tag, sc = true ) # :nodoc:
verbose, $VERBOSE = $VERBOSE, nil
class_eval <<-"end;", __FILE__, __LINE__+1
attr_writer :taguri
@@ -80,12 +79,12 @@ class Module
end
# Transforms the subclass name into a name suitable for display
# in a subclassed tag.
- def yaml_tag_class_name
+ def yaml_tag_class_name # :nodoc:
self.name
end
# Transforms the subclass name found in the tag into a Ruby
# constant name.
- def yaml_tag_read_class( name )
+ def yaml_tag_read_class( name ) # :nodoc:
name
end
end
diff --git a/signal.c b/signal.c
index 0f1171b30b..4f57d455b2 100644
--- a/signal.c
+++ b/signal.c
@@ -264,14 +264,17 @@ esignal_init(argc, argv, self)
}
static VALUE
-interrupt_init(self, mesg)
- VALUE self, mesg;
+interrupt_init(argc, argv, self)
+ int argc;
+ VALUE *argv;
+ VALUE self;
{
- VALUE argv[2];
+ VALUE args[2];
- argv[0] = INT2FIX(SIGINT);
- argv[1] = mesg;
- return rb_call_super(2, argv);
+ args[0] = INT2FIX(SIGINT);
+ rb_scan_args(argc, argv, "01", &args[1]);
+
+ return rb_call_super(2, args);
}
void
@@ -1071,7 +1074,7 @@ Init_signal()
rb_define_method(rb_eSignal, "initialize", esignal_init, -1);
rb_attr(rb_eSignal, rb_intern("signo"), 1, 0, 0);
rb_alias(rb_eSignal, rb_intern("signm"), rb_intern("message"));
- rb_define_method(rb_eInterrupt, "initialize", interrupt_init, 1);
+ rb_define_method(rb_eInterrupt, "initialize", interrupt_init, -1);
install_sighandler(SIGINT, sighandler);
#ifdef SIGHUP