summaryrefslogtreecommitdiff
path: root/thread_pthread.c
diff options
context:
space:
mode:
Diffstat (limited to 'thread_pthread.c')
-rw-r--r--thread_pthread.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/thread_pthread.c b/thread_pthread.c
index 01ad0ce4b5..68ca08f18f 100644
--- a/thread_pthread.c
+++ b/thread_pthread.c
@@ -596,17 +596,17 @@ enum {
RUBY_STACK_MIN_LIMIT = 512 * 1024, /* 512KB */
#endif
RUBY_STACK_SPACE_LIMIT = 1024 * 1024,
+ RUBY_STACK_SPACE_RATIO = 5
+};
#ifdef PTHREAD_STACK_MIN
- RUBY_STACK_MIN = ((RUBY_STACK_MIN_LIMIT < PTHREAD_STACK_MIN) ?
- PTHREAD_STACK_MIN * 2 : RUBY_STACK_MIN_LIMIT),
+#define RUBY_STACK_MIN ((RUBY_STACK_MIN_LIMIT < PTHREAD_STACK_MIN) ? \
+ PTHREAD_STACK_MIN * 2 : RUBY_STACK_MIN_LIMIT)
#else
- RUBY_STACK_MIN = (RUBY_STACK_MIN_LIMIT),
+#define RUBY_STACK_MIN (RUBY_STACK_MIN_LIMIT)
#endif
- RUBY_STACK_SPACE_RATIO = 5,
- RUBY_STACK_MIN_SPACE = RUBY_STACK_MIN/RUBY_STACK_SPACE_RATIO,
- RUBY_STACK_SPACE = ((RUBY_STACK_MIN_SPACE > RUBY_STACK_SPACE_LIMIT) ?
- RUBY_STACK_SPACE_LIMIT : RUBY_STACK_MIN_SPACE)
-};
+#define RUBY_STACK_MIN_SPACE RUBY_STACK_MIN/RUBY_STACK_SPACE_RATIO
+#define RUBY_STACK_SPACE ((RUBY_STACK_MIN_SPACE > RUBY_STACK_SPACE_LIMIT) ? \
+ RUBY_STACK_SPACE_LIMIT : RUBY_STACK_MIN_SPACE)
#ifdef STACK_END_ADDRESS
extern void *STACK_END_ADDRESS;