-
Notifications
You must be signed in to change notification settings - Fork 2k
Open
Description
The In Operator seems to have been broken for a while...
if 'github.com' in "https://github.com/jashkenas/coffeescript/issues/5481"
alert 'Found'
Does not work (using the version on https://coffeescript.org/)
It renders to
var indexOf = [].indexOf;
if (indexOf.call("https://github.com/jashkenas/coffeescript/issues/5481", 'github.com') >= 0) {
alert('found');:
}
Which doesn´t work:
indexOf.call("https://github.com/jashkenas/coffeescript/issues/5481", 'github.com')
-1
indexOf.call('github.com', "https://github.com/jashkenas/coffeescript/issues/5481")
-1
This works though
"https://github.com/jashkenas/coffeescript/issues/5481".indexOf('github.com')
37
That´s in chrome, not sure when indexOf.call is kinda broken
Metadata
Metadata
Assignees
Labels
No labels