Index: src/js/string-iterator.js |
diff --git a/src/js/string-iterator.js b/src/js/string-iterator.js |
index 3c331dd1a2da4e99dc0e84be7c9ffa091f01acad..af9af31efd884ef1322c625ed4fc9676e7dd1383 100644 |
--- a/src/js/string-iterator.js |
+++ b/src/js/string-iterator.js |
@@ -32,6 +32,7 @@ function StringIterator() {} |
// 21.1.5.1 CreateStringIterator Abstract Operation |
function CreateStringIterator(string) { |
+ CHECK_OBJECT_COERCIBLE(string, 'String.prototype[Symbol.iterator]'); |
var s = TO_STRING(string); |
var iterator = new StringIterator; |
SET_PRIVATE(iterator, stringIteratorIteratedStringSymbol, s); |