diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-08-07 09:08:29 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-08-07 09:08:29 +0000 |
commit | 41d220441da76c69c1a7d3b58687f0bbf3d8166d (patch) | |
tree | a5b98a5ef153019b21b3854f29d724d0f0b24e92 /object.c | |
parent | f5f6859b42851cd19be6a3aaed55318b45cf40d0 (diff) | |
download | bundler-41d220441da76c69c1a7d3b58687f0bbf3d8166d.tar.gz |
deprecate TRUE,FALSE,NIL
* object.c (InitVM_Object): deprecate toplevel constants TRUE,
FALSE, and NIL. [Feature #12574]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55824 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'object.c')
-rw-r--r-- | object.c | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -3613,6 +3613,14 @@ InitVM_Object(void) * An alias of +false+ */ rb_define_global_const("FALSE", Qfalse); + + { + VALUE names[3]; + names[0] = ID2SYM(rb_intern_const("TRUE")); + names[1] = ID2SYM(rb_intern_const("FALSE")); + names[2] = ID2SYM(rb_intern_const("NIL")); + rb_mod_deprecate_constant(3, names, rb_cObject); + } } void |