{"action":"created","issue":{"url":"https://api.github.com/repos/mozilla/rhino/issues/204","labels_url":"https://api.github.com/repos/mozilla/rhino/issues/204/labels{/name}","comments_url":"https://api.github.com/repos/mozilla/rhino/issues/204/comments","events_url":"https://api.github.com/repos/mozilla/rhino/issues/204/events","html_url":"https://github.com/mozilla/rhino/pull/204","id":89312543,"number":204,"title":"ES5 handling of null and undefined passed as this to Function.prototype.call / Function.prototype.apply","user":{"login":"eshepelyuk","id":1279477,"avatar_url":"https://avatars.githubusercontent.com/u/1279477?v=3","gravatar_id":"","url":"https://api.github.com/users/eshepelyuk","html_url":"https://github.com/eshepelyuk","followers_url":"https://api.github.com/users/eshepelyuk/followers","following_url":"https://api.github.com/users/eshepelyuk/following{/other_user}","gists_url":"https://api.github.com/users/eshepelyuk/gists{/gist_id}","starred_url":"https://api.github.com/users/eshepelyuk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eshepelyuk/subscriptions","organizations_url":"https://api.github.com/users/eshepelyuk/orgs","repos_url":"https://api.github.com/users/eshepelyuk/repos","events_url":"https://api.github.com/users/eshepelyuk/events{/privacy}","received_events_url":"https://api.github.com/users/eshepelyuk/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-06-18T14:44:47Z","updated_at":"2015-06-23T14:11:20Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/mozilla/rhino/pulls/204","html_url":"https://github.com/mozilla/rhino/pull/204","diff_url":"https://github.com/mozilla/rhino/pull/204.diff","patch_url":"https://github.com/mozilla/rhino/pull/204.patch"},"body":"@gbrail @sainaen \r\n\r\n1. Before ES5 null or undefined passed as thisArg were replaced by Global scope object. This PR \r\nintroduces new flag that controls if we have to keep old behaviour or ES5 compatible\r\n2. Additionally this PR intorduces control of ES6 method using Rhino language version. So now if `find` / `findIndex` / `String.repeat` etc are used with version < ES6 - exception will be thrown\r\n\r\nThis PR should help to properly resolve #174  \r\n\r\n##### Note \r\nDue to current `Rhino` method signatures `undefined` can not be forwarded to function as spec say.\r\nRhino mostly accepts `Scriptable` instances and `Undefined` doesn't implement this interface."},"comment":{"url":"https://api.github.com/repos/mozilla/rhino/issues/comments/114518779","html_url":"https://github.com/mozilla/rhino/pull/204#issuecomment-114518779","issue_url":"https://api.github.com/repos/mozilla/rhino/issues/204","id":114518779,"user":{"login":"eshepelyuk","id":1279477,"avatar_url":"https://avatars.githubusercontent.com/u/1279477?v=3","gravatar_id":"","url":"https://api.github.com/users/eshepelyuk","html_url":"https://github.com/eshepelyuk","followers_url":"https://api.github.com/users/eshepelyuk/followers","following_url":"https://api.github.com/users/eshepelyuk/following{/other_user}","gists_url":"https://api.github.com/users/eshepelyuk/gists{/gist_id}","starred_url":"https://api.github.com/users/eshepelyuk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eshepelyuk/subscriptions","organizations_url":"https://api.github.com/users/eshepelyuk/orgs","repos_url":"https://api.github.com/users/eshepelyuk/repos","events_url":"https://api.github.com/users/eshepelyuk/events{/privacy}","received_events_url":"https://api.github.com/users/eshepelyuk/received_events","type":"User","site_admin":false},"created_at":"2015-06-23T14:11:20Z","updated_at":"2015-06-23T14:11:20Z","body":"As for me - 1st option is easier and it seems the way Rhino` did before.\r\nSo, let me fix this ES6 restrictions for those particular methods if you agree to proceed with Option 1 "}}