summaryrefslogtreecommitdiff
path: root/include/ruby/impl/newobj.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/ruby/impl/newobj.h')
-rw-r--r--include/ruby/impl/newobj.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/include/ruby/impl/newobj.h b/include/ruby/impl/newobj.h
index 38f53145b1..ccfc7d9a7d 100644
--- a/include/ruby/impl/newobj.h
+++ b/include/ruby/impl/newobj.h
@@ -1,5 +1,5 @@
-#ifndef RUBY3_NEWOBJ_H /*-*-C++-*-vi:se ft=cpp:*/
-#define RUBY3_NEWOBJ_H
+#ifndef RBIMPL_NEWOBJ_H /*-*-C++-*-vi:se ft=cpp:*/
+#define RBIMPL_NEWOBJ_H
/**
* @file
* @author Ruby developers <ruby-core@ruby-lang.org>
@@ -7,7 +7,7 @@
* 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.
- * @warning Symbols prefixed with either `RUBY3` or `ruby3` are
+ * @warning Symbols prefixed with either `RBIMPL` or `ruby3` are
* implementation details. Don't take them as canon. They could
* rapidly appear then vanish. The name (path) of this header file
* is also an implementation detail. Do not expect it to persist
@@ -28,8 +28,8 @@
#include "ruby/impl/value.h"
#include "ruby/assert.h"
-#define RB_NEWOBJ(obj,type) type *(obj) = RUBY3_CAST((type *)rb_newobj())
-#define RB_NEWOBJ_OF(obj,type,klass,flags) type *(obj) = RUBY3_CAST((type *)rb_newobj_of(klass, flags))
+#define RB_NEWOBJ(obj,type) type *(obj) = RBIMPL_CAST((type *)rb_newobj())
+#define RB_NEWOBJ_OF(obj,type,klass,flags) type *(obj) = RBIMPL_CAST((type *)rb_newobj_of(klass, flags))
#define NEWOBJ RB_NEWOBJ
#define NEWOBJ_OF RB_NEWOBJ_OF /* core has special NEWOBJ_OF() in internal.h */
@@ -37,7 +37,7 @@
#define CLONESETUP rb_clone_setup
#define DUPSETUP rb_dup_setup
-RUBY3_SYMBOL_EXPORT_BEGIN()
+RBIMPL_SYMBOL_EXPORT_BEGIN()
VALUE rb_newobj(void);
VALUE rb_newobj_of(VALUE, VALUE);
VALUE rb_obj_setup(VALUE obj, VALUE klass, VALUE type);
@@ -45,13 +45,13 @@ VALUE rb_obj_class(VALUE);
VALUE rb_singleton_class_clone(VALUE);
void rb_singleton_class_attached(VALUE,VALUE);
void rb_copy_generic_ivar(VALUE,VALUE);
-RUBY3_SYMBOL_EXPORT_END()
+RBIMPL_SYMBOL_EXPORT_END()
static inline void
rb_clone_setup(VALUE clone, VALUE obj)
{
- RUBY3_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(obj));
- RUBY3_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(clone));
+ RBIMPL_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(obj));
+ RBIMPL_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(clone));
const VALUE flags = RUBY_FL_PROMOTED0 | RUBY_FL_PROMOTED1 | RUBY_FL_FINALIZE;
rb_obj_setup(clone, rb_singleton_class_clone(obj),
@@ -63,11 +63,11 @@ rb_clone_setup(VALUE clone, VALUE obj)
static inline void
rb_dup_setup(VALUE dup, VALUE obj)
{
- RUBY3_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(obj));
- RUBY3_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(dup));
+ RBIMPL_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(obj));
+ RBIMPL_ASSERT_OR_ASSUME(! RB_SPECIAL_CONST_P(dup));
rb_obj_setup(dup, rb_obj_class(obj), RB_FL_TEST_RAW(obj, RUBY_FL_DUPPED));
if (RB_FL_TEST(obj, RUBY_FL_EXIVAR)) rb_copy_generic_ivar(dup, obj);
}
-#endif /* RUBY3_NEWOBJ_H */
+#endif /* RBIMPL_NEWOBJ_H */