summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-09-01 07:25:25 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-09-01 07:25:25 +0000
commitcff9ebc8dcdab943fa7b48b97ef42e6c1fd58f1c (patch)
treea42b760319f85d37afab6d4f8af0038901772ec7
parent2252d4ce028b38bb46310b215b2c98afbf224d55 (diff)
matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@923 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog2
-rw-r--r--eval.c26
-rw-r--r--misc/ruby-mode.el5
3 files changed, 19 insertions, 14 deletions
diff --git a/ChangeLog b/ChangeLog
index 0f6364d..3a285e5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,8 @@ Fri Sep 1 10:36:45 2000 Yukihiro Matsumoto <matz@ruby-lang.org>
Fri Sep 1 10:36:29 2000 Yukihiro Matsumoto <matz@ruby-lang.org>
+ * eval.c (Init_eval): extend room for stack allowance.
+
* eval.c (POP_SCOPE): frees scope too much.
Thu Aug 31 14:28:39 2000 Yukihiro Matsumoto <matz@ruby-lang.org>
diff --git a/eval.c b/eval.c
index be0303e..b485cf8 100644
--- a/eval.c
+++ b/eval.c
@@ -5652,8 +5652,8 @@ Init_eval()
if (getrlimit(RLIMIT_STACK, &rlim) == 0) {
double space = (double)rlim.rlim_cur*0.2;
- if (space > 256*1024) space = 256*1024;
- STACK_LEVEL_MAX = (rlim.rlim_cur - space) / 4;
+ if (space > 1024*1024) space = 1024*1024;
+ STACK_LEVEL_MAX = (rlim.rlim_cur - space) / sizeof(VALUE);
}
}
#endif
@@ -6025,20 +6025,20 @@ proc_call(proc, args)
ruby_safe_level = safe;
if (state) {
- if (orphan) {/* orphan procedure */
- switch (state) {
- case TAG_BREAK:
- rb_raise(rb_eLocalJumpError, "break from proc-closure");
- break;
- case TAG_RETRY:
- rb_raise(rb_eLocalJumpError, "retry from proc-closure");
- break;
- case TAG_RETURN:
+ switch (state) {
+ case TAG_BREAK:
+ break;
+ case TAG_RETRY:
+ rb_raise(rb_eLocalJumpError, "retry from proc-closure");
+ break;
+ case TAG_RETURN:
+ if (orphan) { /* orphan procedure */
rb_raise(rb_eLocalJumpError, "return from proc-closure");
- break;
}
+ /* fall through */
+ default:
+ JUMP_TAG(state);
}
- JUMP_TAG(state);
}
return result;
}
diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el
index cffd853..782d049 100644
--- a/misc/ruby-mode.el
+++ b/misc/ruby-mode.el
@@ -694,7 +694,10 @@ An end of a defun is found by moving forward from the beginning of one."
(make-local-variable 'font-lock-syntactic-keywords)
(setq font-lock-syntactic-keywords
'(("\\$\\([#\"'`$\\]\\)" 1 (1 . nil))
- ("\\(#\\)[{$@]" 1 (1 . nil))))
+ ("\\(#\\)[{$@]" 1 (1 . nil))
+ ("\\(/\\).*\\(/\\)"
+ (1 (7 . ?'))
+ (2 (7 . ?')))))
(make-local-variable 'font-lock-defaults)
(setq font-lock-defaults '((ruby-font-lock-keywords) nil nil))
(setq font-lock-keywords ruby-font-lock-keywords)))