TIL in Web ECMAScript. Has the potential to be a memory leak in a very rare scenario.pic.twitter.com/BORGQQQMhA
You can add location information to your Tweets, such as your city or precise location, from the web and via third-party applications. You always have the option to delete your Tweet location history. Learn more
@sebmck don't suppose you know of a functional regex parser that does not have all the side effects of the stateful, native RegExp?
@hurricanejames Not really. Performance would be terrible as native regexes are extremely performant and optimised.
@sebmck Thought it can hold only the last nine captured groups?
@grabbou There's RegExp.lastMatch and RegExp["$&"] too.
@sebmck more like security leak!
.@sebmck It's not the worst thing: `var s = hugeString.slice(0, 1)` keeps entire `hugeString` in memory until `s` is released in V8.
@sebmck Even more fun when you reuse some single small node from an old AST in new one, but entire 2 MB source is retained in RAM.
@sebmck and don't forget RegExp['$&'] that will always keep pthe whole string in ^_^
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.