Feature #9502
closedRemove deprecated definitions
Description
I'd like to remove deprecated definitions.
This means C level API change.
The list of functions, macros and types are follows.
(This list doesn't contain definitions deprecated after 2.1.0 release.)
VA VD NAME
old 193 Check_SafeStr -> SafeStringValue
old 193 rb_check_safe_str -> SafeStringValue
old 193 rb_quad_pack -> rb_integer_pack
old 193 rb_quad_unpack -> rb_integer_unpack
old 193 rb_read_check : access struct FILE internal. no replacement.
old 193 rb_struct_iv_get : internal function. no replacement.
191 * struct rb_blocking_region_buffer : internal type. no replacement.
191 193 rb_thread_blocking_region_begin -> rb_thread_call_without_gvl family
191 193 rb_thread_blocking_region_end -> rb_thread_call_without_gvl family
old 193 TRAP_BEG -> rb_thread_call_without_gvl family
old 193 TRAP_END -> rb_thread_call_without_gvl family
old 193 rb_thread_select -> rb_thread_fd_select
191 * struct rb_exec_arg : internal type. no replacement.
191 200 rb_exec : internal function. no replacement.
191 200 rb_exec_arg_addopt : internal function. no replacement.
191 200 rb_exec_arg_fixup : internal function. no replacement.
191 200 rb_exec_arg_init : internal function. no replacement.
192 200 rb_exec_err : internal function. no replacement.
191 200 rb_fork : internal function. no replacement.
192 200 rb_fork_err : internal function. no replacement.
191 200 rb_proc_exec_n : internal function. no replacement.
191 200 rb_run_exec_options : internal function. no replacement.
192 200 rb_run_exec_options_err : internal function. no replacement.
191 200 rb_thread_blocking_region -> rb_thread_call_without_gvl family
old 200 rb_thread_polling -> rb_thread_wait_for
186 210 rb_big2str0 : internal function. no replacement.
193 210 rb_big2ulong_pack -> rb_integer_pack
193 210 rb_gc_set_params : internal function. no replacement.
VA is the version that the definition is available since.
"old" means it is available since 1.8.5 at least.
VD is the version that the definition is deprecated to cause warnings.
"*" means struct type.
struct types are not a target of deprecation warning.
It seems the half of definitions have replacements.
The rest are removed without replacement because they are ruby internals.
Files
Updated by nobu (Nobuyoshi Nakada) almost 11 years ago
Agree.
And today I've thought about deprecation of rb_argv0
too.
Updated by akr (Akira Tanaka) almost 11 years ago
We should provide a transition period.
So I didn't list definitions deprecated after Ruby 2.1 such as rb_str_associate.
They will be warned at Ruby 2.2 and can be removed at Ruby 2.3 or later.
rb_argv0 can be same as rb_str_associate if you deprecated it now.
But it is used in ext/tk.
So you need to remove the use before the deprecation.
Updated by matz (Yukihiro Matsumoto) almost 11 years ago
Agreed. Remove those functions (structs).
Matz.
Updated by akr (Akira Tanaka) almost 11 years ago
- Status changed from Open to Closed
- % Done changed from 0 to 100
Applied in changeset r44955.
- include/ruby/intern.h,
include/ruby/io.h,
include/ruby/ruby.h,
include/ruby/win32.h,
include/ruby/backward/rubysig.h,
bignum.c,
gc.c,
io.c,
process.c,
safe.c,
struct.c,
thread.c,
ext/socket/rubysocket.h,
ext/-test-/old_thread_select: Remove deprecated definitions
[ruby-core:60581] [Feature #9502]
Updated by ko1 (Koichi Sasada) almost 11 years ago
I copied this table to the following page:
https://bugs.ruby-lang.org/projects/ruby-trunk/wiki/CAPI_ObsoleteFunctions
Maybe we can maintain this page for deprecated definitions.
Updated by ko1 (Koichi Sasada) almost 11 years ago
Koichi Sasada wrote:
I copied this table to the following page:
https://bugs.ruby-lang.org/projects/ruby-trunk/wiki/CAPI_ObsoleteFunctions
Not only functions. So I renamed to:
https://bugs.ruby-lang.org/projects/ruby-trunk/wiki/CAPI_obsolete_definitions