summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-06-12 04:46:16 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-06-12 04:46:16 +0000
commit69fa5eea6a2b1f658ed21263f17699393b04bc6e (patch)
tree06b36afaae1197244852757fb1af4a25f7af974f /include
parent53f0a8ade14ff8bb82cc1c7cd4c28139acdd4734 (diff)
* include/ruby/ruby.h (rb_intern): use rb_intern2 with strlen for
constant symbols to optimize strlen. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17105 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
-rw-r--r--include/ruby/ruby.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h
index 5bae5d392d..d2b9f4c8b3 100644
--- a/include/ruby/ruby.h
+++ b/include/ruby/ruby.h
@@ -768,7 +768,7 @@ VALUE rb_id2str(ID);
{ \
static ID rb_intern_id_cache; \
if (!rb_intern_id_cache) \
- rb_intern_id_cache = (rb_intern)(str); \
+ rb_intern_id_cache = rb_intern2(str, strlen(str)); \
result rb_intern_id_cache; \
}
#define CONST_ID(var, str) \