summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-22 10:23:06 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-22 10:23:06 +0000
commit8ef2aae2d0350506fb1b12eb0afd56b5b1f51b89 (patch)
tree179a6c280d1b1ce254edb7c0ff2b88449350b437
parentdb68ccc20da6a3668dc514f128b3236e455822d0 (diff)
Use idException
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66495 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--complex.c2
-rw-r--r--object.c2
-rw-r--r--process.c4
-rw-r--r--rational.c2
4 files changed, 5 insertions, 5 deletions
diff --git a/complex.c b/complex.c
index 685d4bc075..35e56283ef 100644
--- a/complex.c
+++ b/complex.c
@@ -438,7 +438,7 @@ nucomp_f_complex(int argc, VALUE *argv, VALUE klass)
static ID kwds[1];
VALUE exception;
if (!kwds[0]) {
- kwds[0] = rb_intern_const("exception");
+ kwds[0] = idException;
}
rb_get_kwargs(opts, kwds, 0, 1, &exception);
raise = (exception != Qfalse);
diff --git a/object.c b/object.c
index faf6db7d8f..637a301791 100644
--- a/object.c
+++ b/object.c
@@ -3213,7 +3213,7 @@ opts_exception_p(VALUE opts)
static ID kwds[1];
VALUE exception;
if (!kwds[0]) {
- kwds[0] = rb_intern_const("exception");
+ kwds[0] = idException;
}
rb_get_kwargs(opts, kwds, 0, 1, &exception);
return exception != Qfalse;
diff --git a/process.c b/process.c
index d395b19c29..d629dd9321 100644
--- a/process.c
+++ b/process.c
@@ -250,7 +250,8 @@ typedef unsigned LONG_LONG unsigned_clock_t;
typedef void (*sig_t) (int);
#endif
-static ID id_in, id_out, id_err, id_pid, id_uid, id_gid, id_exception;
+#define id_exception idException
+static ID id_in, id_out, id_err, id_pid, id_uid, id_gid;
static ID id_close, id_child;
#ifdef HAVE_SETPGID
static ID id_pgroup;
@@ -8497,7 +8498,6 @@ Init_process(void)
id_MACH_ABSOLUTE_TIME_BASED_CLOCK_MONOTONIC = rb_intern("MACH_ABSOLUTE_TIME_BASED_CLOCK_MONOTONIC");
#endif
id_hertz = rb_intern("hertz");
- id_exception = rb_intern("exception");
InitVM(process);
}
diff --git a/rational.c b/rational.c
index 076d42707f..a6a94368e8 100644
--- a/rational.c
+++ b/rational.c
@@ -575,7 +575,7 @@ nurat_f_rational(int argc, VALUE *argv, VALUE klass)
static ID kwds[1];
VALUE exception;
if (!kwds[0]) {
- kwds[0] = rb_intern_const("exception");
+ kwds[0] = idException;
}
rb_get_kwargs(opts, kwds, 0, 1, &exception);
raise = (exception != Qfalse);