aboutsummaryrefslogtreecommitdiff
path: root/src/pkg/runtime/alg.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/pkg/runtime/alg.c')
-rw-r--r--src/pkg/runtime/alg.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/pkg/runtime/alg.c b/src/pkg/runtime/alg.c
index bc848da38c..ce872755ff 100644
--- a/src/pkg/runtime/alg.c
+++ b/src/pkg/runtime/alg.c
@@ -324,6 +324,10 @@ runtime·strequal(bool *eq, uintptr s, void *a, void *b)
*eq = false;
return;
}
+ if(((String*)a)->str == ((String*)b)->str) {
+ *eq = true;
+ return;
+ }
runtime·memequal(eq, alen, ((String*)a)->str, ((String*)b)->str);
}