Last active
March 16, 2017 03:50
-
-
Save etale/81bd22a72efea60a8c17d6622fdce1b8 to your computer and use it in GitHub Desktop.
an iterator for Number
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Reflect.set(Number.prototype, Symbol.iterator, function* () { let i = 0; while (i < this) yield i++ }) |
Author
etale
commented
Jan 16, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment