Skip to content

Commit fbb61a2

Browse files
committed
Mark old Data API as deprecated
[Feature #19998]
1 parent d4aff75 commit fbb61a2

File tree

1 file changed

+2
-15
lines changed

1 file changed

+2
-15
lines changed

include/ruby/internal/core/rdata.h

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,8 @@
3737
#include "ruby/defines.h"
3838

3939
/** @cond INTERNAL_MACRO */
40-
#ifdef RUBY_UNTYPED_DATA_WARNING
41-
# /* Take that. */
42-
#elif defined(RUBY_EXPORT)
43-
# define RUBY_UNTYPED_DATA_WARNING 1
44-
#else
45-
# define RUBY_UNTYPED_DATA_WARNING 0
40+
#ifndef RUBY_UNTYPED_DATA_WARNING
41+
#define RUBY_UNTYPED_DATA_WARNING 1
4642
#endif
4743

4844
#define RBIMPL_DATA_FUNC(f) RBIMPL_CAST((void (*)(void *))(f))
@@ -331,15 +327,6 @@ rb_data_object_get_warning(VALUE obj)
331327
return rb_data_object_get(obj);
332328
}
333329

334-
#if defined(HAVE_BUILTIN___BUILTIN_CHOOSE_EXPR_CONSTANT_P)
335-
# define rb_data_object_wrap_warning(klass, ptr, mark, free) \
336-
RB_GNUC_EXTENSION( \
337-
__builtin_choose_expr( \
338-
__builtin_constant_p(klass) && !(klass), \
339-
rb_data_object_wrap(klass, ptr, mark, free), \
340-
(rb_data_object_wrap_warning)(klass, ptr, mark, free)))
341-
#endif
342-
343330
/**
344331
* This is an implementation detail of #Data_Make_Struct. People don't use it
345332
* directly.

0 commit comments

Comments
 (0)