summaryrefslogtreecommitdiff
path: root/error.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-04-04 15:42:16 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-04-04 15:42:16 +0000
commitf1796fdb2c0473f2362a79402e1d9417cf2b6f96 (patch)
tree5e7befe525fdb14e5f2896b0eaa43e61e7292167 /error.c
parent8259e4aa9a140b9584dec2be4e542dfbd71a40ad (diff)
* error.c (rb_notimplement), io.c (pipe_open): removed definite
articles and UNIX manual section from messages. [ruby-dev:30690] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'error.c')
-rw-r--r--error.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/error.c b/error.c
index 2d4bafdf50..b80afa881d 100644
--- a/error.c
+++ b/error.c
@@ -1027,8 +1027,8 @@ rb_loaderror(const char *fmt, ...)
void
rb_notimplement(void)
{
- rb_raise(rb_eNotImpError,
- "The %s() function is unimplemented on this machine",
+ rb_raise(rb_eNotImpError,
+ "%s() function is unimplemented on this machine",
rb_id2name(rb_frame_this_func()));
}
@@ -1473,21 +1473,21 @@ Init_syserr(void)
static void
err_append(const char *s)
{
- rb_thread_t *th = GET_THREAD();
- if (th->parse_in_eval) {
- if (NIL_P(th->errinfo)) {
- th->errinfo = rb_exc_new2(rb_eSyntaxError, s);
+ rb_thread_t *th = GET_THREAD();
+ if (th->parse_in_eval) {
+ if (NIL_P(th->errinfo)) {
+ th->errinfo = rb_exc_new2(rb_eSyntaxError, s);
+ }
+ else {
+ VALUE str = rb_obj_as_string(GET_THREAD()->errinfo);
+
+ rb_str_cat2(str, "\n");
+ rb_str_cat2(str, s);
+ th->errinfo = rb_exc_new3(rb_eSyntaxError, str);
+ }
}
else {
- VALUE str = rb_obj_as_string(GET_THREAD()->errinfo);
-
- rb_str_cat2(str, "\n");
- rb_str_cat2(str, s);
- th->errinfo = rb_exc_new3(rb_eSyntaxError, str);
+ rb_write_error(s);
+ rb_write_error("\n");
}
- }
- else {
- rb_write_error(s);
- rb_write_error("\n");
- }
}