mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
use C style comments instead of C++ style comments
According to CONTRIBUTING.md, Don't use C++ style comments /* This is the prefered comment style */ Use C++ style comments only for temporary comment e.g. commenting out some code lines.
This commit is contained in:
+19
-19
@@ -9,61 +9,61 @@
|
||||
|
||||
/* configuration options: */
|
||||
/* add -DMRB_USE_FLOAT to use float instead of double for floating point numbers */
|
||||
//#define MRB_USE_FLOAT
|
||||
/* #define MRB_USE_FLOAT */
|
||||
|
||||
/* add -DMRB_INT16 to use 16bit integer for mrb_int; conflict with MRB_INT64 */
|
||||
//#define MRB_INT16
|
||||
/* #define MRB_INT16 */
|
||||
|
||||
/* add -DMRB_INT64 to use 64bit integer for mrb_int; conflict with MRB_INT16 */
|
||||
//#define MRB_INT64
|
||||
/* #define MRB_INT64 */
|
||||
|
||||
/* represent mrb_value in boxed double; conflict with MRB_USE_FLOAT */
|
||||
//#define MRB_NAN_BOXING
|
||||
/* #define MRB_NAN_BOXING */
|
||||
|
||||
/* define on big endian machines; used by MRB_NAN_BOXING */
|
||||
//#define MRB_ENDIAN_BIG
|
||||
/* #define MRB_ENDIAN_BIG */
|
||||
|
||||
/* represent mrb_value as a word (natural unit of data for the processor) */
|
||||
// #define MRB_WORD_BOXING
|
||||
/* #define MRB_WORD_BOXING */
|
||||
|
||||
/* argv max size in mrb_funcall */
|
||||
//#define MRB_FUNCALL_ARGC_MAX 16
|
||||
/* #define MRB_FUNCALL_ARGC_MAX 16 */
|
||||
|
||||
/* number of object per heap page */
|
||||
//#define MRB_HEAP_PAGE_SIZE 1024
|
||||
/* #define MRB_HEAP_PAGE_SIZE 1024 */
|
||||
|
||||
/* use segmented list for IV table */
|
||||
//#define MRB_USE_IV_SEGLIST
|
||||
/* #define MRB_USE_IV_SEGLIST */
|
||||
|
||||
/* initial size for IV khash; ignored when MRB_USE_IV_SEGLIST is set */
|
||||
//#define MRB_IVHASH_INIT_SIZE 8
|
||||
/* #define MRB_IVHASH_INIT_SIZE 8 */
|
||||
|
||||
/* turn off generational GC by default */
|
||||
//#define MRB_GC_TURN_OFF_GENERATIONAL
|
||||
/* #define MRB_GC_TURN_OFF_GENERATIONAL */
|
||||
|
||||
/* default size of khash table bucket */
|
||||
//#define KHASH_DEFAULT_SIZE 32
|
||||
/* #define KHASH_DEFAULT_SIZE 32 */
|
||||
|
||||
/* allocated memory address alignment */
|
||||
//#define POOL_ALIGNMENT 4
|
||||
/* #define POOL_ALIGNMENT 4 */
|
||||
|
||||
/* page size of memory pool */
|
||||
//#define POOL_PAGE_SIZE 16000
|
||||
/* #define POOL_PAGE_SIZE 16000 */
|
||||
|
||||
/* initial minimum size for string buffer */
|
||||
//#define MRB_STR_BUF_MIN_SIZE 128
|
||||
/* #define MRB_STR_BUF_MIN_SIZE 128 */
|
||||
|
||||
/* arena size */
|
||||
//#define MRB_GC_ARENA_SIZE 100
|
||||
/* #define MRB_GC_ARENA_SIZE 100 */
|
||||
|
||||
/* fixed size GC arena */
|
||||
//#define MRB_GC_FIXED_ARENA
|
||||
/* #define MRB_GC_FIXED_ARENA */
|
||||
|
||||
/* -DDISABLE_XXXX to drop following features */
|
||||
//#define DISABLE_STDIO /* use of stdio */
|
||||
/* #define DISABLE_STDIO */ /* use of stdio */
|
||||
|
||||
/* -DENABLE_XXXX to enable following features */
|
||||
//#define ENABLE_DEBUG /* hooks for debugger */
|
||||
/* #define ENABLE_DEBUG */ /* hooks for debugger */
|
||||
|
||||
/* end of configuration */
|
||||
|
||||
|
||||
+1
-1
@@ -304,7 +304,7 @@ mrb_value mrb_obj_clone(mrb_state *mrb, mrb_value self);
|
||||
|
||||
/* need to include <ctype.h> to use these macros */
|
||||
#ifndef ISPRINT
|
||||
//#define ISASCII(c) isascii((int)(unsigned char)(c))
|
||||
/* #define ISASCII(c) isascii((int)(unsigned char)(c)) */
|
||||
#define ISASCII(c) 1
|
||||
#define ISPRINT(c) (ISASCII(c) && isprint((int)(unsigned char)(c)))
|
||||
#define ISSPACE(c) (ISASCII(c) && isspace((int)(unsigned char)(c)))
|
||||
|
||||
@@ -55,17 +55,17 @@ mrb_irep *mrb_read_irep(mrb_state*, const uint8_t*);
|
||||
|
||||
#define MRB_DUMP_DEFAULT_STR_LEN 128
|
||||
|
||||
// binary header
|
||||
/* binary header */
|
||||
struct rite_binary_header {
|
||||
uint8_t binary_identify[4]; // Binary Identifier
|
||||
uint8_t binary_version[4]; // Binary Format Version
|
||||
uint8_t binary_crc[2]; // Binary CRC
|
||||
uint8_t binary_size[4]; // Binary Size
|
||||
uint8_t compiler_name[4]; // Compiler name
|
||||
uint8_t binary_identify[4]; /* Binary Identifier */
|
||||
uint8_t binary_version[4]; /* Binary Format Version */
|
||||
uint8_t binary_crc[2]; /* Binary CRC */
|
||||
uint8_t binary_size[4]; /* Binary Size */
|
||||
uint8_t compiler_name[4]; /* Compiler name */
|
||||
uint8_t compiler_version[4];
|
||||
};
|
||||
|
||||
// section header
|
||||
/* section header */
|
||||
#define RITE_SECTION_HEADER \
|
||||
uint8_t section_identify[4]; \
|
||||
uint8_t section_size[4]
|
||||
@@ -77,7 +77,7 @@ struct rite_section_header {
|
||||
struct rite_section_irep_header {
|
||||
RITE_SECTION_HEADER;
|
||||
|
||||
uint8_t rite_version[4]; // Rite Instruction Specification Version
|
||||
uint8_t rite_version[4]; /* Rite Instruction Specification Version */
|
||||
};
|
||||
|
||||
struct rite_section_lineno_header {
|
||||
|
||||
@@ -24,7 +24,7 @@ typedef khint_t khiter_t;
|
||||
|
||||
#define UPPER_BOUND(x) ((x)>>2|(x)>>1)
|
||||
|
||||
//extern uint8_t __m[];
|
||||
/* extern uint8_t __m[]; */
|
||||
|
||||
/* mask for flags */
|
||||
static const uint8_t __m_empty[8] = {0x02, 0x08, 0x20, 0x80};
|
||||
|
||||
@@ -16,9 +16,9 @@ typedef struct global_variable {
|
||||
mrb_value *data;
|
||||
mrb_value (*getter)(void);
|
||||
void (*setter)(void);
|
||||
//void (*marker)();
|
||||
//int block_trace;
|
||||
//struct trace_var *trace;
|
||||
/* void (*marker)(); */
|
||||
/* int block_trace; */
|
||||
/* struct trace_var *trace; */
|
||||
} global_variable;
|
||||
|
||||
struct global_entry {
|
||||
|
||||
Reference in New Issue
Block a user