diff options
Diffstat (limited to 'internal')
51 files changed, 156 insertions, 152 deletions
diff --git a/internal/array.h b/internal/array.h index b566f48435..8f346aad63 100644 --- a/internal/array.h +++ b/internal/array.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_ARRAY_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_ARRAY_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Array. */ -#ifndef INTERNAL_ARRAY_H -#define INTERNAL_ARRAY_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ #include "internal/static_assert.h" /* for STATIC_ASSERT */ diff --git a/internal/bignum.h b/internal/bignum.h index a49ecd8c0e..6850a14399 100644 --- a/internal/bignum.h +++ b/internal/bignum.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_BIGNUM_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_BIGNUM_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Bignums. */ -#ifndef INTERNAL_BIGNUM_H -#define INTERNAL_BIGNUM_H #include "ruby/3/config.h" /* for HAVE_LIBGMP */ #include <stddef.h> /* for size_t */ diff --git a/internal/bits.h b/internal/bits.h index 28c668dd21..1dc5531d8c 100644 --- a/internal/bits.h +++ b/internal/bits.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_BITS_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_BITS_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -24,8 +26,6 @@ * @see https://software.intel.com/sites/landingpage/IntrinsicsGuide/#text=_rotr64 * @see https://stackoverflow.com/a/776523 */ -#ifndef INTERNAL_BITS_H -#define INTERNAL_BITS_H #include "ruby/3/config.h" #include <limits.h> /* for CHAR_BITS */ #include <stdint.h> /* for uintptr_t */ diff --git a/internal/class.h b/internal/class.h index f5df0a6a70..7b9400b38b 100644 --- a/internal/class.h +++ b/internal/class.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_CLASS_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_CLASS_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Class. */ -#ifndef INTERNAL_CLASS_H -#define INTERNAL_CLASS_H #include "id_table.h" /* for struct rb_id_table */ #include "internal/gc.h" /* for RB_OBJ_WRITE */ #include "internal/serial.h" /* for rb_serial_t */ diff --git a/internal/compar.h b/internal/compar.h index aba1cdf25e..888a3b5e1e 100644 --- a/internal/compar.h +++ b/internal/compar.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_COMPAR_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_COMPAR_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Comparable. */ -#ifndef INTERNAL_COMPAR_H -#define INTERNAL_COMPAR_H #include "internal/vm.h" /* for rb_method_basic_definition_p */ #define STRING_P(s) (RB_TYPE_P((s), T_STRING) && CLASS_OF(s) == rb_cString) diff --git a/internal/compile.h b/internal/compile.h index 468d3d0a6b..435fbfe22a 100644 --- a/internal/compile.h +++ b/internal/compile.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_COMPILE_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_COMPILE_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for the compiler. */ -#ifndef INTERNAL_COMPILE_H -#define INTERNAL_COMPILE_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ #include "ruby/ruby.h" /* for rb_event_flag_t */ diff --git a/internal/compilers.h b/internal/compilers.h index 591b5de9ed..10b119b61b 100644 --- a/internal/compilers.h +++ b/internal/compilers.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_COMPILERS_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_COMPILERS_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header absorbing C compipler differences. */ -#ifndef INTERNAL_COMPILERS_H -#define INTERNAL_COMPILERS_H #include "ruby/3/compiler_since.h" #include "ruby/3/has/attribute.h" #include "ruby/3/has/builtin.h" diff --git a/internal/complex.h b/internal/complex.h index f435f143ef..afabd36fbc 100644 --- a/internal/complex.h +++ b/internal/complex.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_COMPLEX_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_COMPLEX_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,9 +9,7 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Complex. */ -#ifndef INTERNAL_COMPLEX_H -#define INTERNAL_COMPLEX_H -#include "ruby/ruby.h" /* for struct RBasic */ +#include "ruby/3/value.h" /* for struct RBasic */ struct RComplex { struct RBasic basic; diff --git a/internal/cont.h b/internal/cont.h index 9b7dd9a9e4..81874aa5c7 100644 --- a/internal/cont.h +++ b/internal/cont.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_CONT_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_CONT_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Fiber. */ -#ifndef INTERNAL_CONT_H -#define INTERNAL_CONT_H #include "ruby/ruby.h" /* for VALUE */ struct rb_thread_struct; /* in vm_core.h */ diff --git a/internal/dir.h b/internal/dir.h index fa165b67bd..ffbdb25208 100644 --- a/internal/dir.h +++ b/internal/dir.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_DIR_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_DIR_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Dir. */ -#ifndef INTERNAL_DIR_H -#define INTERNAL_DIR_H #include "ruby/ruby.h" /* for VALUE */ /* dir.c */ diff --git a/internal/enc.h b/internal/enc.h index 79a52b94a8..0afc74db5d 100644 --- a/internal/enc.h +++ b/internal/enc.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_ENC_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_ENC_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Encoding. */ -#ifndef INTERNAL_ENC_H -#define INTERNAL_ENC_H #include "ruby/encoding.h" /* for rb_encoding */ /* us_ascii.c */ diff --git a/internal/encoding.h b/internal/encoding.h index 62a35093e7..af236daeaf 100644 --- a/internal/encoding.h +++ b/internal/encoding.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_ENCODING_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_ENCODING_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Encoding. */ -#ifndef INTERNAL_ENCODING_H -#define INTERNAL_ENCODING_H #include "ruby/ruby.h" /* for ID */ #include "ruby/encoding.h" /* for rb_encoding */ diff --git a/internal/enum.h b/internal/enum.h index d14a7b367a..50890f0c9f 100644 --- a/internal/enum.h +++ b/internal/enum.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_ENUM_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_ENUM_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Enumerable. */ -#ifndef INTERNAL_ENUM_H -#define INTERNAL_ENUM_H #include "ruby/ruby.h" /* for VALUE */ /* enum.c */ diff --git a/internal/enumerator.h b/internal/enumerator.h index f9b3fdac4f..2e20c37d9e 100644 --- a/internal/enumerator.h +++ b/internal/enumerator.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_ENUMERATOR_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_ENUMERATOR_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Enumerator. */ -#ifndef INTERNAL_ENUMERATOR_H -#define INTERNAL_ENUMERATOR_H #include "ruby/ruby.h" /* for VALUE */ #include "ruby/intern.h" /* for rb_enumerator_size_func */ diff --git a/internal/error.h b/internal/error.h index 5b44f25624..5a9b6cd834 100644 --- a/internal/error.h +++ b/internal/error.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_ERROR_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_ERROR_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Exception. */ -#ifndef INTERNAL_ERROR_H -#define INTERNAL_ERROR_H #include "ruby/3/config.h" #include <stdarg.h> /* for va_list */ #include "internal/string.h" /* for rb_fstring_cstr */ diff --git a/internal/eval.h b/internal/eval.h index 75c07692d4..8dae76b6f8 100644 --- a/internal/eval.h +++ b/internal/eval.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_EVAL_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_EVAL_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -9,8 +11,6 @@ * @note There also is eval_intern.h, which is evaluator's internal * header (related to this file, but not the same role). */ -#ifndef INTERNAL_EVAL_H -#define INTERNAL_EVAL_H #include "ruby/ruby.h" /* for ID */ #define id_signo ruby_static_id_signo diff --git a/internal/file.h b/internal/file.h index 4b87d0dddf..a93c1392f0 100644 --- a/internal/file.h +++ b/internal/file.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_FILE_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_FILE_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for File. */ -#ifndef INTERNAL_FILE_H -#define INTERNAL_FILE_H #include "ruby/ruby.h" /* for VALUE */ #include "ruby/encoding.h" /* for rb_encodinng */ diff --git a/internal/fixnum.h b/internal/fixnum.h index f6313855eb..5d081488f7 100644 --- a/internal/fixnum.h +++ b/internal/fixnum.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_FIXNUM_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_FIXNUM_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Fixnums. */ -#ifndef INTERNAL_FIXNUM_H -#define INTERNAL_FIXNUM_H #include "ruby/3/config.h" /* for HAVE_LONG_LONG */ #include <limits.h> /* for CHAR_BIT */ #include "internal/compilers.h" /* for __has_builtin */ diff --git a/internal/gc.h b/internal/gc.h index 451f461de0..fb4b1bbde9 100644 --- a/internal/gc.h +++ b/internal/gc.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_GC_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_GC_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for GC. */ -#ifndef INTERNAL_GC_H -#define INTERNAL_GC_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ diff --git a/internal/hash.h b/internal/hash.h index 4c2e663a65..f33d225953 100644 --- a/internal/hash.h +++ b/internal/hash.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_HASH_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_HASH_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Hash. */ -#ifndef INTERNAL_HASH_H -#define INTERNAL_HASH_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ #include "ruby/3/stdbool.h" /* for bool */ diff --git a/internal/imemo.h b/internal/imemo.h index 3475606e90..0fbbac3a4c 100644 --- a/internal/imemo.h +++ b/internal/imemo.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_IMEMO_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_IMEMO_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief IMEMO: Internal memo object. */ -#ifndef INTERNAL_IMEMO_H -#define INTERNAL_IMEMO_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ #include "internal/array.h" /* for rb_ary_tmp_new_fill */ diff --git a/internal/inits.h b/internal/inits.h index e0d417455d..680c9cc1a5 100644 --- a/internal/inits.h +++ b/internal/inits.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_INITS_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_INITS_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header aggregating init functions. */ -#ifndef INTERNAL_INITS_H -#define INTERNAL_INITS_H /* class.c */ void Init_class_hierarchy(void); diff --git a/internal/io.h b/internal/io.h index 6578d0b683..b184cec439 100644 --- a/internal/io.h +++ b/internal/io.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_IO_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_IO_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for IO. */ -#ifndef INTERNAL_IO_H -#define INTERNAL_IO_H #include "ruby/ruby.h" /* for VALUE */ #include "ruby/io.h" /* for rb_io_t */ diff --git a/internal/load.h b/internal/load.h index febf9eb200..37c1dee351 100644 --- a/internal/load.h +++ b/internal/load.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_LOAD_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_LOAD_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for require. */ -#ifndef INTERNAL_LOAD_H -#define INTERNAL_LOAD_H #include "ruby/ruby.h" /* for VALUE */ /* load.c */ diff --git a/internal/loadpath.h b/internal/loadpath.h index b975d4992d..f89f6694cd 100644 --- a/internal/loadpath.h +++ b/internal/loadpath.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_LOADPATH_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_LOADPATH_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for $LOAD_PATH. */ -#ifndef INTERNAL_LOADPATH_H -#define INTERNAL_LOADPATH_H /* loadpath.c */ extern const char ruby_exec_prefix[]; diff --git a/internal/math.h b/internal/math.h index bbf4f798dd..cd8d553790 100644 --- a/internal/math.h +++ b/internal/math.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_MATH_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_MATH_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Math. */ -#ifndef INTERNAL_MATH_H -#define INTERNAL_MATH_H #include "ruby/ruby.h" /* for VALUE */ /* math.c */ diff --git a/internal/missing.h b/internal/missing.h index 866b8aa472..cff5f94729 100644 --- a/internal/missing.h +++ b/internal/missing.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_MISSING_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_MISSING_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header corresponding missing. */ -#ifndef INTERNAL_MISSING_H -#define INTERNAL_MISSING_H #include "ruby/3/config.h" /* for HAVE_SETPROCTITLE */ /* missing/setproctitle.c */ diff --git a/internal/mjit.h b/internal/mjit.h index 47f620bc39..0f8540592b 100644 --- a/internal/mjit.h +++ b/internal/mjit.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_MJIT_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_MJIT_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for MJIT. */ -#ifndef INTERNAL_MJIT_H -#define INTERNAL_MJIT_H #include "ruby/3/stdbool.h" /* for bool */ #include "ruby/ruby.h" /* for VALUE */ diff --git a/internal/numeric.h b/internal/numeric.h index cd5347f5d2..219e739e7d 100644 --- a/internal/numeric.h +++ b/internal/numeric.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_NUMERIC_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_NUMERIC_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Numeric. */ -#ifndef INTERNAL_NUMERIC_H -#define INTERNAL_NUMERIC_H #include "internal/bignum.h" /* for BIGNUM_POSITIVE_P */ #include "internal/bits.h" /* for RUBY_BIT_ROTL */ #include "internal/fixnum.h" /* for FIXNUM_POSITIVE_P */ diff --git a/internal/object.h b/internal/object.h index a2d053bbb4..a05abbf971 100644 --- a/internal/object.h +++ b/internal/object.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_OBJECT_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_OBJECT_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Object. */ -#ifndef INTERNAL_OBJECT_H -#define INTERNAL_OBJECT_H #include "ruby/ruby.h" /* for VALUE */ /* object.c */ diff --git a/internal/parse.h b/internal/parse.h index bcfe0c2d0e..a37a39f84d 100644 --- a/internal/parse.h +++ b/internal/parse.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_PARSE_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_PARSE_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for the parser. */ -#ifndef INTERNAL_PARSE_H -#define INTERNAL_PARSE_H #include "ruby/ruby.h" /* for VALUE */ struct rb_iseq_struct; /* in vm_core.h */ diff --git a/internal/proc.h b/internal/proc.h index aebaf28fb0..3d4c611584 100644 --- a/internal/proc.h +++ b/internal/proc.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_PROC_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_PROC_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Proc. */ -#ifndef INTERNAL_PROC_H -#define INTERNAL_PROC_H #include "ruby/ruby.h" /* for rb_block_call_func_t */ #include "ruby/st.h" /* for st_index_t */ struct rb_block; /* in vm_core.h */ diff --git a/internal/process.h b/internal/process.h index 5c8af817a8..b47f857bb4 100644 --- a/internal/process.h +++ b/internal/process.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_PROCESS_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_PROCESS_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Process. */ -#ifndef INTERNAL_PROCESS_H -#define INTERNAL_PROCESS_H #include "ruby/3/config.h" /* for rb_pid_t */ #include <stddef.h> /* for size_t */ diff --git a/internal/random.h b/internal/random.h index 008b644700..a92e65b8ba 100644 --- a/internal/random.h +++ b/internal/random.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_RANDOM_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_RANDOM_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Random. */ -#ifndef INTERNAL_RANDOM_H -#define INTERNAL_RANDOM_H #include <stddef.h> /* for size_t */ /* random.c */ diff --git a/internal/range.h b/internal/range.h index 948072ebf0..0b60f42298 100644 --- a/internal/range.h +++ b/internal/range.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_RANGE_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_RANGE_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Range. */ -#ifndef INTERNAL_RANGE_H -#define INTERNAL_RANGE_H #include "internal/struct.h" /* for RSTRUCT */ /* range.c */ diff --git a/internal/rational.h b/internal/rational.h index 1e64b4a799..8006470df7 100644 --- a/internal/rational.h +++ b/internal/rational.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_RATIONAL_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_RATIONAL_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Rational. */ -#ifndef INTERNAL_RATIONAL_H -#define INTERNAL_RATIONAL_H #include "ruby/3/config.h" /* for HAVE_LIBGMP */ #include "ruby/ruby.h" /* for struct RBasic */ #include "internal/gc.h" /* for RB_OBJ_WRITE */ diff --git a/internal/re.h b/internal/re.h index b769ce30b3..f771c4e8a0 100644 --- a/internal/re.h +++ b/internal/re.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_RE_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_RE_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Regexp. */ -#ifndef INTERNAL_RE_H -#define INTERNAL_RE_H #include "ruby/3/stdbool.h" /* for bool */ #include "ruby/ruby.h" /* for VALUE */ diff --git a/internal/sanitizers.h b/internal/sanitizers.h index 7ef5959916..81ee7e3ea5 100644 --- a/internal/sanitizers.h +++ b/internal/sanitizers.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_SANITIZERS_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_SANITIZERS_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for ASAN / MSAN / etc. */ -#ifndef INTERNAL_SANITIZERS_H -#define INTERNAL_SANITIZERS_H #include "ruby/3/config.h" #include "internal/compilers.h" /* for __has_feature */ diff --git a/internal/serial.h b/internal/serial.h index 143d7c6819..518cef4e93 100644 --- a/internal/serial.h +++ b/internal/serial.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_SERIAL_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_SERIAL_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for rb_serial_t. */ -#ifndef INTERNAL_SERIAL_H -#define INTERNAL_SERIAL_H #include "ruby/3/config.h" /* for HAVE_LONG_LONG */ #include "ruby/defines.h" /* for LONG_LONG */ diff --git a/internal/signal.h b/internal/signal.h index 352052550f..6b4672f15b 100644 --- a/internal/signal.h +++ b/internal/signal.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_SIGNAL_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_SIGNAL_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for SignalException. */ -#ifndef INTERNAL_SIGNAL_H -#define INTERNAL_SIGNAL_H /* signal.c */ extern int ruby_enable_coredump; diff --git a/internal/static_assert.h b/internal/static_assert.h index 7b20b252d2..cc6a59713f 100644 --- a/internal/static_assert.h +++ b/internal/static_assert.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_STATIC_ASSERT_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_STATIC_ASSERT_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -11,3 +13,5 @@ #ifndef STATIC_ASSERT # define STATIC_ASSERT RUBY3_STATIC_ASSERT #endif + +#endif /* INTERNAL_STATIC_ASSERT_H */ diff --git a/internal/string.h b/internal/string.h index 7635fa9ebf..f550719f96 100644 --- a/internal/string.h +++ b/internal/string.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_STRING_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_STRING_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for String. */ -#ifndef INTERNAL_STRING_H -#define INTERNAL_STRING_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ #include "internal/compilers.h" /* for __has_builtin */ diff --git a/internal/struct.h b/internal/struct.h index 66efbf3712..2fdd6631de 100644 --- a/internal/struct.h +++ b/internal/struct.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_STRUCT_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_STRUCT_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Struct. */ -#ifndef INTERNAL_STRUCT_H -#define INTERNAL_STRUCT_H #include "ruby/3/stdbool.h" /* for bool */ #include "internal/gc.h" /* for RB_OBJ_WRITE */ #include "ruby/ruby.h" /* for struct RBasic */ diff --git a/internal/symbol.h b/internal/symbol.h index 8a354ffbab..691df66228 100644 --- a/internal/symbol.h +++ b/internal/symbol.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_SYMBOL_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_SYMBOL_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Symbol. */ -#ifndef INTERNAL_SYMBOL_H -#define INTERNAL_SYMBOL_H #include "ruby/ruby.h" /* for VALUE */ #include "ruby/encoding.h" /* for rb_encoding */ #include "internal/compilers.h" /* for __has_builtin */ diff --git a/internal/thread.h b/internal/thread.h index b5cae53e6d..ac09923be0 100644 --- a/internal/thread.h +++ b/internal/thread.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_THREAD_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_THREAD_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Thread. */ -#ifndef INTERNAL_THREAD_H -#define INTERNAL_THREAD_H #include "ruby/ruby.h" /* for VALUE */ #include "ruby/intern.h" /* for rb_blocking_function_t */ diff --git a/internal/time.h b/internal/time.h index 3566dfe564..d7dc34e3dd 100644 --- a/internal/time.h +++ b/internal/time.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_TIME_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_TIME_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Time. */ -#ifndef INTERNAL_TIME_H -#define INTERNAL_TIME_H #include "ruby/3/config.h" /* for SIGNEDNESS_OF_TIME_T */ #include "internal/bits.h" /* for SIGNED_INTEGER_MAX */ #include "ruby/ruby.h" /* for VALUE */ diff --git a/internal/transcode.h b/internal/transcode.h index 5f0a7845b7..452e13a1a6 100644 --- a/internal/transcode.h +++ b/internal/transcode.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_TRANSCODE_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_TRANSCODE_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for Encoding::Converter. */ -#ifndef INTERNAL_TRANSCODE_H -#define INTERNAL_TRANSCODE_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ #include "ruby/ruby.h" /* for VALUE */ diff --git a/internal/util.h b/internal/util.h index ba35c789a2..fdb3f3020a 100644 --- a/internal/util.h +++ b/internal/util.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_UTIL_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_UTIL_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -8,8 +10,6 @@ * @brief Internal header corresponding util.c. * @warning DO NOT ADD RANDOM GARBAGE HERE THIS FILE IS FOR util.c */ -#ifndef INTERNAL_UTIL_H /* -*- C -*- */ -#define INTERNAL_UTIL_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ diff --git a/internal/variable.h b/internal/variable.h index fb0b4a47e8..a3b8f7963d 100644 --- a/internal/variable.h +++ b/internal/variable.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_VARIABLE_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_VARIABLE_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for variables. */ -#ifndef INTERNAL_VARIABLE_H -#define INTERNAL_VARIABLE_H #include "ruby/3/config.h" #include <stddef.h> /* for size_t */ #include "constant.h" /* for rb_const_entry_t */ diff --git a/internal/vm.h b/internal/vm.h index 85fa82332b..1c76913e5c 100644 --- a/internal/vm.h +++ b/internal/vm.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_VM_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_VM_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header for RubyVM. */ -#ifndef INTERNAL_VM_H -#define INTERNAL_VM_H #include "ruby/3/stdbool.h" /* for bool */ #include "internal/serial.h" /* for rb_serial_t */ #include "internal/static_assert.h" /* for STATIC_ASSERT */ diff --git a/internal/warnings.h b/internal/warnings.h index a1705a6867..ae41dcba23 100644 --- a/internal/warnings.h +++ b/internal/warnings.h @@ -1,4 +1,6 @@ -/** \noop-*-C-*-vi:ft=c +#ifndef INTERNAL_WARNINGS_H /*-*-C-*-vi:se ft=c:*/ +#define INTERNAL_WARNINGS_H +/** * @file * @author Ruby developers <ruby-core@ruby-lang.org> * @copyright This file is a part of the programming language Ruby. @@ -7,8 +9,6 @@ * file COPYING are met. Consult the file for details. * @brief Internal header to suppres / mandate warnings. */ -#ifndef INTERNAL_WARNINGS_H -#define INTERNAL_WARNINGS_H #include "ruby/3/warning_push.h" #define COMPILER_WARNING_PUSH RUBY3_WARNING_PUSH() #define COMPILER_WARNING_POP RUBY3_WARNING_POP() |