summaryrefslogtreecommitdiff
path: root/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'string.c')
-rw-r--r--string.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/string.c b/string.c
index 42a1f3b79f..da00bb4bf3 100644
--- a/string.c
+++ b/string.c
@@ -565,6 +565,7 @@ static VALUE
rb_str_equal(str1, str2)
VALUE str1, str2;
{
+ if (str1 == str2) return Qtrue;
if (TYPE(str2) != T_STRING)
return Qfalse;