{"action":"created","issue":{"url":"https://api.github.com/repos/tc39/ecmascript_sharedmem/issues/69","repository_url":"https://api.github.com/repos/tc39/ecmascript_sharedmem","labels_url":"https://api.github.com/repos/tc39/ecmascript_sharedmem/issues/69/labels{/name}","comments_url":"https://api.github.com/repos/tc39/ecmascript_sharedmem/issues/69/comments","events_url":"https://api.github.com/repos/tc39/ecmascript_sharedmem/issues/69/events","html_url":"https://github.com/tc39/ecmascript_sharedmem/issues/69","id":136991736,"number":69,"title":"Why use numbers for enum values?","user":{"login":"erights","id":273868,"avatar_url":"https://avatars.githubusercontent.com/u/273868?v=3","gravatar_id":"","url":"https://api.github.com/users/erights","html_url":"https://github.com/erights","followers_url":"https://api.github.com/users/erights/followers","following_url":"https://api.github.com/users/erights/following{/other_user}","gists_url":"https://api.github.com/users/erights/gists{/gist_id}","starred_url":"https://api.github.com/users/erights/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/erights/subscriptions","organizations_url":"https://api.github.com/users/erights/orgs","repos_url":"https://api.github.com/users/erights/repos","events_url":"https://api.github.com/users/erights/events{/privacy}","received_events_url":"https://api.github.com/users/erights/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/tc39/ecmascript_sharedmem/labels/Synchronic","name":"Synchronic","color":"009800"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2016-02-28T01:37:42Z","updated_at":"2016-03-23T17:59:19Z","closed_at":null,"body":"http://tc39.github.io/ecmascript_sharedmem/shmem.html#AtomicsObjectValueProps says:\r\n\r\n> 7.1.1 Atomics.OK\r\n>   The value 0.\r\n> 7.1.2 Atomics.NOTEQUAL\r\n>   The value -1.\r\n> 7.1.3 Atomics.TIMEDOUT\r\n>   The value -2.\r\n\r\nFor JavaScript, this seems a bizarre choice. Literal strings are interned. Why not just use the strings 'OK', 'NOTEQUAL', and 'TIMEDOUT'?"},"comment":{"url":"https://api.github.com/repos/tc39/ecmascript_sharedmem/issues/comments/200467341","html_url":"https://github.com/tc39/ecmascript_sharedmem/issues/69#issuecomment-200467341","issue_url":"https://api.github.com/repos/tc39/ecmascript_sharedmem/issues/69","id":200467341,"user":{"login":"lars-t-hansen","id":4823190,"avatar_url":"https://avatars.githubusercontent.com/u/4823190?v=3","gravatar_id":"","url":"https://api.github.com/users/lars-t-hansen","html_url":"https://github.com/lars-t-hansen","followers_url":"https://api.github.com/users/lars-t-hansen/followers","following_url":"https://api.github.com/users/lars-t-hansen/following{/other_user}","gists_url":"https://api.github.com/users/lars-t-hansen/gists{/gist_id}","starred_url":"https://api.github.com/users/lars-t-hansen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lars-t-hansen/subscriptions","organizations_url":"https://api.github.com/users/lars-t-hansen/orgs","repos_url":"https://api.github.com/users/lars-t-hansen/repos","events_url":"https://api.github.com/users/lars-t-hansen/events{/privacy}","received_events_url":"https://api.github.com/users/lars-t-hansen/received_events","type":"User","site_admin":false},"created_at":"2016-03-23T17:59:19Z","updated_at":"2016-03-23T17:59:19Z","body":"That's right, it would basically prevent calling futexWait from asm.js.  Since futexWait is really quite expensive already I've struct the general attitude that that's not a big deal.\r\n\r\nA couple of thoughts:\r\n* I think that asm.js will probably be overtaken by wasm in a year or maybe two and that we can live with this extra cost until then, at which point it won't matter much\r\n* We can actually hack string literals into asm.js for this case: all the other Atomic methods are effectively treated as syntax by asm.js anyway, with at least our asm.js compiler requiring certain syntactic forms for the arguments.\r\n\r\nBut if you feel otherwise this is a good time to argue..."}}