2020-04-10 01:11:40 -04:00
|
|
|
#ifndef RUBY_RUBY_BACKWARD_H /*-*-C++-*-vi:se ft=cpp:*/
|
2016-01-06 21:34:33 -05:00
|
|
|
#define RUBY_RUBY_BACKWARD_H 1
|
2020-04-10 01:11:40 -04:00
|
|
|
/**
|
|
|
|
* @file
|
|
|
|
* @author Ruby developers <ruby-core@ruby-lang.org>
|
|
|
|
* @copyright This file is a part of the programming language Ruby.
|
|
|
|
* Permission is hereby granted, to either redistribute and/or
|
|
|
|
* modify this file, provided that the conditions mentioned in the
|
|
|
|
* file COPYING are met. Consult the file for details.
|
|
|
|
*/
|
2020-05-08 05:31:09 -04:00
|
|
|
#include "ruby/internal/value.h"
|
|
|
|
#include "ruby/internal/interpreter.h"
|
2020-04-08 00:28:13 -04:00
|
|
|
#include "ruby/backward/2/attributes.h"
|
2016-01-06 21:34:33 -05:00
|
|
|
|
2020-12-30 06:56:10 -05:00
|
|
|
#define RBIMPL_ATTR_DEPRECATED_SINCE(ver) RBIMPL_ATTR_DEPRECATED(("since " #ver))
|
2020-12-30 22:23:29 -05:00
|
|
|
#define RBIMPL_ATTR_DEPRECATED_INTERNAL(ver) RBIMPL_ATTR_DEPRECATED(("since "#ver", also internal"))
|
2017-02-21 00:17:41 -05:00
|
|
|
|
|
|
|
/* eval.c */
|
2020-12-30 06:56:10 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.2) void rb_disable_super();
|
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.2) void rb_enable_super();
|
2017-02-21 00:17:41 -05:00
|
|
|
|
|
|
|
/* hash.c */
|
2020-12-30 06:56:10 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.2) void rb_hash_iter_lev();
|
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.2) void rb_hash_ifnone();
|
2017-02-21 00:17:41 -05:00
|
|
|
|
|
|
|
/* string.c */
|
2020-12-30 06:56:10 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.2) void rb_str_associate();
|
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.2) void rb_str_associated();
|
2017-02-21 00:17:41 -05:00
|
|
|
|
2017-02-21 01:16:50 -05:00
|
|
|
/* variable.c */
|
2020-12-30 06:56:10 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.5) void rb_autoload();
|
2017-02-21 01:07:22 -05:00
|
|
|
|
2018-07-27 09:57:14 -04:00
|
|
|
/* eval.c */
|
2020-12-30 22:23:29 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.6) void rb_frozen_class_p();
|
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.7) void rb_exec_end_proc();
|
2018-07-27 09:57:14 -04:00
|
|
|
|
2017-02-21 01:07:22 -05:00
|
|
|
/* error.c */
|
2020-12-30 22:23:29 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.3) void rb_compile_error();
|
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.3) void rb_compile_error_with_enc();
|
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.3) void rb_compile_error_append();
|
2017-02-21 01:07:22 -05:00
|
|
|
|
2019-08-12 04:44:30 -04:00
|
|
|
/* gc.c */
|
2020-12-30 22:23:29 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.7) void rb_gc_call_finalizer_at_exit();
|
2019-08-12 04:44:30 -04:00
|
|
|
|
|
|
|
/* signal.c */
|
2020-12-30 22:23:29 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.7) void rb_trap_exit();
|
2019-08-12 04:44:30 -04:00
|
|
|
|
2017-02-21 01:07:22 -05:00
|
|
|
/* struct.c */
|
2020-12-30 22:23:29 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.4) void rb_struct_ptr();
|
2017-02-21 01:07:22 -05:00
|
|
|
|
2019-08-12 04:44:30 -04:00
|
|
|
/* thread.c */
|
2020-12-30 22:23:29 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.7) void rb_clear_trace_func();
|
2019-08-12 04:44:30 -04:00
|
|
|
|
2017-02-21 01:16:49 -05:00
|
|
|
/* variable.c */
|
2020-12-30 22:23:29 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.7) void rb_generic_ivar_table();
|
2020-12-30 22:30:13 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_INTERNAL(2.6) NORETURN(VALUE rb_mod_const_missing(VALUE, VALUE));
|
2017-02-21 01:16:49 -05:00
|
|
|
|
2017-02-21 00:17:41 -05:00
|
|
|
/* from version.c */
|
2020-07-21 22:30:05 -04:00
|
|
|
#if defined(RUBY_SHOW_COPYRIGHT_TO_DIE) && !!(RUBY_SHOW_COPYRIGHT_TO_DIE+0)
|
2016-01-06 21:34:33 -05:00
|
|
|
/* for source code backward compatibility */
|
2020-12-30 06:56:10 -05:00
|
|
|
RBIMPL_ATTR_DEPRECATED_SINCE(2.4)
|
2016-01-06 21:34:33 -05:00
|
|
|
static inline int
|
|
|
|
ruby_show_copyright_to_die(int exitcode)
|
|
|
|
{
|
|
|
|
ruby_show_copyright();
|
|
|
|
return exitcode;
|
|
|
|
}
|
|
|
|
#define ruby_show_copyright() /* defer EXIT_SUCCESS */ \
|
|
|
|
(exit(ruby_show_copyright_to_die(EXIT_SUCCESS)))
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif /* RUBY_RUBY_BACKWARD_H */
|