From a3abda46b041213614658ca4d8bf441ce5ebb2d5 Mon Sep 17 00:00:00 2001 From: nobu Date: Mon, 23 Jan 2017 06:16:04 +0000 Subject: object.c: no TypeError at Symbol * object.c (special_object_p): uninterned Symbol also should not raise a TypeError but return itself instead, as well as interned Symbols. [ruby-core:79216] [Bug #13145] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57407 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- object.c | 1 + 1 file changed, 1 insertion(+) (limited to 'object.c') diff --git a/object.c b/object.c index 3a9a556947..6f4b1239c8 100644 --- a/object.c +++ b/object.c @@ -304,6 +304,7 @@ special_object_p(VALUE obj) switch (BUILTIN_TYPE(obj)) { case T_BIGNUM: case T_FLOAT: + case T_SYMBOL: return TRUE; default: return FALSE; -- cgit v1.2.3