[#3726] Fixnum#clone and Float#clone raise different exceptions — "David A. Black" <dblack@...>

Hi --

15 messages 2004/11/12
[#3749] Re: Fixnum#clone and Float#clone raise different exceptions — "David A. Black" <dblack@...> 2004/11/16

Hi --

[#3751] Re: Fixnum#clone and Float#clone raise different exceptions — Yukihiro Matsumoto <matz@...> 2004/11/16

Hi,

[#3752] Re: Fixnum#clone and Float#clone raise different exceptions — "David A. Black" <dblack@...> 2004/11/16

Hi --

[#3785] The latest 1.8.2 cvs prints parse error when starting extension compiling — Yukihiro Matsumoto <matz@...>

Hi,

13 messages 2004/11/23
[#3787] Re: The latest 1.8.2 cvs prints parse error when starting extension compiling — Johan Holmberg <holmberg@...> 2004/11/23

[BUG] Readline.completion_append_character in latest snapshot

From: Joel VanderWerf <vjoel@...>
Date: 2004-11-19 00:18:44 UTC
List: ruby-core #3765
In ruby 1.9.0 (2004-11-18) [i686-linux], something changed in readline, 
which broke irb -r irb/completion.

$ irb -r irb/completion
/usr/local/lib/ruby/1.9/irb/completion.rb:187:in 
`completion_append_character=':TypeError: cannot convert nil into String

The offending line is:

Readline.completion_append_character = nil

but the problem is likely in readline.c, where the following changed:

@@ -195,7 +203,9 @@
      VALUE self, str;
  {
  #ifdef READLINE_21_OR_LATER
-    if (NIL_P(str) || !StringValuePtr(str) || !RSTRING(str)->len) {
+    rb_secure(4);
+    SafeStringValue(str);
+    if (NIL_P(str) || RSTRING(str)->len == 0) {
         rl_completion_append_character = '\0';
      } else {
         rl_completion_append_character = RSTRING(str)->ptr[0];



I guess SafeStringValue rejects Qnil.

In This Thread

Prev Next