Skip to content

Commit

Permalink
Mark CharSequence.iterator() with operator.
Browse files Browse the repository at this point in the history
  • Loading branch information
ilya-g committed Sep 28, 2015
1 parent 3c39328 commit de7262a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libraries/stdlib/src/kotlin/text/Strings.kt
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ public fun String?.isNullOrBlank(): Boolean = this == null || this.isBlank()
/**
* Iterator for characters of given CharSequence.
*/
public fun CharSequence.iterator(): CharIterator = object : CharIterator() {
public operator fun CharSequence.iterator(): CharIterator = object : CharIterator() {
private var index = 0

public override fun nextChar(): Char = get(index++)
Expand Down

0 comments on commit de7262a

Please sign in to comment.