{"action":"created","comment":{"url":"https://api.github.com/repos/kripken/emscripten/pulls/comments/32093859","id":32093859,"diff_hunk":"@@ -252,16 +260,10 @@ def build(self, src, dirname, filename, output_processor=None, main_file=None, a\n       output_processor(open(filename + '.o.js').read())\n \n     if self.emcc_args is not None:\n-      if '--memory-init-file' in self.emcc_args:\n-        memory_init_file = int(self.emcc_args[self.emcc_args.index('--memory-init-file')+1])\n-      else:\n-        memory_init_file = ('-O2' in self.emcc_args or '-O3' in self.emcc_args or '-Oz' in self.emcc_args) and not Settings.SIDE_MODULE\n       src = open(filename + '.o.js').read()\n-      if memory_init_file:\n+      if self.uses_memory_init_file():\n         # side memory init file, or an empty one in the js\n         assert ('/* memory initializer */' not in src) or ('/* memory initializer */ allocate([]' in src)\n-      else:\n-        assert 'memory initializer */' in src or '/*' not in src # memory initializer comment, or cleaned-up source with no comments","path":"tests/runner.py","position":29,"original_position":29,"commit_id":"3a7c14bc19381e35a70b67c12d815967a798ff44","original_commit_id":"3a7c14bc19381e35a70b67c12d815967a798ff44","user":{"login":"gagern","id":190759,"avatar_url":"https://avatars.githubusercontent.com/u/190759?v=3","gravatar_id":"","url":"https://api.github.com/users/gagern","html_url":"https://github.com/gagern","followers_url":"https://api.github.com/users/gagern/followers","following_url":"https://api.github.com/users/gagern/following{/other_user}","gists_url":"https://api.github.com/users/gagern/gists{/gist_id}","starred_url":"https://api.github.com/users/gagern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gagern/subscriptions","organizations_url":"https://api.github.com/users/gagern/orgs","repos_url":"https://api.github.com/users/gagern/repos","events_url":"https://api.github.com/users/gagern/events{/privacy}","received_events_url":"https://api.github.com/users/gagern/received_events","type":"User","site_admin":false},"body":"@kripken: Judging from your lack of comment on this line, I take it that dropping this particular check is OK?","created_at":"2015-06-10T07:29:22Z","updated_at":"2015-06-10T07:29:22Z","html_url":"https://github.com/kripken/emscripten/pull/3326#discussion_r32093859","pull_request_url":"https://api.github.com/repos/kripken/emscripten/pulls/3326","_links":{"self":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/comments/32093859"},"html":{"href":"https://github.com/kripken/emscripten/pull/3326#discussion_r32093859"},"pull_request":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/3326"}}},"pull_request":{"url":"https://api.github.com/repos/kripken/emscripten/pulls/3326","id":32916785,"html_url":"https://github.com/kripken/emscripten/pull/3326","diff_url":"https://github.com/kripken/emscripten/pull/3326.diff","patch_url":"https://github.com/kripken/emscripten/pull/3326.patch","issue_url":"https://api.github.com/repos/kripken/emscripten/issues/3326","number":3326,"state":"open","locked":false,"title":"Memory initializer in string literal","user":{"login":"gagern","id":190759,"avatar_url":"https://avatars.githubusercontent.com/u/190759?v=3","gravatar_id":"","url":"https://api.github.com/users/gagern","html_url":"https://github.com/gagern","followers_url":"https://api.github.com/users/gagern/followers","following_url":"https://api.github.com/users/gagern/following{/other_user}","gists_url":"https://api.github.com/users/gagern/gists{/gist_id}","starred_url":"https://api.github.com/users/gagern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gagern/subscriptions","organizations_url":"https://api.github.com/users/gagern/orgs","repos_url":"https://api.github.com/users/gagern/repos","events_url":"https://api.github.com/users/gagern/events{/privacy}","received_events_url":"https://api.github.com/users/gagern/received_events","type":"User","site_admin":false},"body":"Having the memory initializer as a separate file can become a huge problem in some environments. It would be nice if we could offer more alternatives. I see how big array literals would be kind of bulky. But how about encoding the memory initializer into one or more strings? Here is some code to do that, based on a base 88 encoding scheme. If you like the idea, it would be nice if you could introduce some setting to switch between file and string.","created_at":"2015-04-09T00:58:11Z","updated_at":"2015-06-10T07:29:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d3278e9ff32f62e1bcf398a7accb9a1780be4965","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/kripken/emscripten/pulls/3326/commits","review_comments_url":"https://api.github.com/repos/kripken/emscripten/pulls/3326/comments","review_comment_url":"https://api.github.com/repos/kripken/emscripten/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kripken/emscripten/issues/3326/comments","statuses_url":"https://api.github.com/repos/kripken/emscripten/statuses/3a7c14bc19381e35a70b67c12d815967a798ff44","head":{"label":"gagern:strMemInit","ref":"strMemInit","sha":"3a7c14bc19381e35a70b67c12d815967a798ff44","user":{"login":"gagern","id":190759,"avatar_url":"https://avatars.githubusercontent.com/u/190759?v=3","gravatar_id":"","url":"https://api.github.com/users/gagern","html_url":"https://github.com/gagern","followers_url":"https://api.github.com/users/gagern/followers","following_url":"https://api.github.com/users/gagern/following{/other_user}","gists_url":"https://api.github.com/users/gagern/gists{/gist_id}","starred_url":"https://api.github.com/users/gagern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gagern/subscriptions","organizations_url":"https://api.github.com/users/gagern/orgs","repos_url":"https://api.github.com/users/gagern/repos","events_url":"https://api.github.com/users/gagern/events{/privacy}","received_events_url":"https://api.github.com/users/gagern/received_events","type":"User","site_admin":false},"repo":{"id":8103916,"name":"emscripten","full_name":"gagern/emscripten","owner":{"login":"gagern","id":190759,"avatar_url":"https://avatars.githubusercontent.com/u/190759?v=3","gravatar_id":"","url":"https://api.github.com/users/gagern","html_url":"https://github.com/gagern","followers_url":"https://api.github.com/users/gagern/followers","following_url":"https://api.github.com/users/gagern/following{/other_user}","gists_url":"https://api.github.com/users/gagern/gists{/gist_id}","starred_url":"https://api.github.com/users/gagern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gagern/subscriptions","organizations_url":"https://api.github.com/users/gagern/orgs","repos_url":"https://api.github.com/users/gagern/repos","events_url":"https://api.github.com/users/gagern/events{/privacy}","received_events_url":"https://api.github.com/users/gagern/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gagern/emscripten","description":"Emscripten: An LLVM-to-JavaScript Compiler","fork":true,"url":"https://api.github.com/repos/gagern/emscripten","forks_url":"https://api.github.com/repos/gagern/emscripten/forks","keys_url":"https://api.github.com/repos/gagern/emscripten/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gagern/emscripten/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gagern/emscripten/teams","hooks_url":"https://api.github.com/repos/gagern/emscripten/hooks","issue_events_url":"https://api.github.com/repos/gagern/emscripten/issues/events{/number}","events_url":"https://api.github.com/repos/gagern/emscripten/events","assignees_url":"https://api.github.com/repos/gagern/emscripten/assignees{/user}","branches_url":"https://api.github.com/repos/gagern/emscripten/branches{/branch}","tags_url":"https://api.github.com/repos/gagern/emscripten/tags","blobs_url":"https://api.github.com/repos/gagern/emscripten/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gagern/emscripten/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gagern/emscripten/git/refs{/sha}","trees_url":"https://api.github.com/repos/gagern/emscripten/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gagern/emscripten/statuses/{sha}","languages_url":"https://api.github.com/repos/gagern/emscripten/languages","stargazers_url":"https://api.github.com/repos/gagern/emscripten/stargazers","contributors_url":"https://api.github.com/repos/gagern/emscripten/contributors","subscribers_url":"https://api.github.com/repos/gagern/emscripten/subscribers","subscription_url":"https://api.github.com/repos/gagern/emscripten/subscription","commits_url":"https://api.github.com/repos/gagern/emscripten/commits{/sha}","git_commits_url":"https://api.github.com/repos/gagern/emscripten/git/commits{/sha}","comments_url":"https://api.github.com/repos/gagern/emscripten/comments{/number}","issue_comment_url":"https://api.github.com/repos/gagern/emscripten/issues/comments{/number}","contents_url":"https://api.github.com/repos/gagern/emscripten/contents/{+path}","compare_url":"https://api.github.com/repos/gagern/emscripten/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gagern/emscripten/merges","archive_url":"https://api.github.com/repos/gagern/emscripten/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gagern/emscripten/downloads","issues_url":"https://api.github.com/repos/gagern/emscripten/issues{/number}","pulls_url":"https://api.github.com/repos/gagern/emscripten/pulls{/number}","milestones_url":"https://api.github.com/repos/gagern/emscripten/milestones{/number}","notifications_url":"https://api.github.com/repos/gagern/emscripten/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gagern/emscripten/labels{/name}","releases_url":"https://api.github.com/repos/gagern/emscripten/releases{/id}","created_at":"2013-02-09T00:15:47Z","updated_at":"2015-04-08T20:13:55Z","pushed_at":"2015-06-09T20:54:30Z","git_url":"git://github.com/gagern/emscripten.git","ssh_url":"git@github.com:gagern/emscripten.git","clone_url":"https://github.com/gagern/emscripten.git","svn_url":"https://github.com/gagern/emscripten","homepage":"","size":123607,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"kripken:incoming","ref":"incoming","sha":"92094e41a6cd28adbf11bb08a9f0cd38ac0248b4","user":{"login":"kripken","id":173661,"avatar_url":"https://avatars.githubusercontent.com/u/173661?v=3","gravatar_id":"","url":"https://api.github.com/users/kripken","html_url":"https://github.com/kripken","followers_url":"https://api.github.com/users/kripken/followers","following_url":"https://api.github.com/users/kripken/following{/other_user}","gists_url":"https://api.github.com/users/kripken/gists{/gist_id}","starred_url":"https://api.github.com/users/kripken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kripken/subscriptions","organizations_url":"https://api.github.com/users/kripken/orgs","repos_url":"https://api.github.com/users/kripken/repos","events_url":"https://api.github.com/users/kripken/events{/privacy}","received_events_url":"https://api.github.com/users/kripken/received_events","type":"User","site_admin":false},"repo":{"id":1357796,"name":"emscripten","full_name":"kripken/emscripten","owner":{"login":"kripken","id":173661,"avatar_url":"https://avatars.githubusercontent.com/u/173661?v=3","gravatar_id":"","url":"https://api.github.com/users/kripken","html_url":"https://github.com/kripken","followers_url":"https://api.github.com/users/kripken/followers","following_url":"https://api.github.com/users/kripken/following{/other_user}","gists_url":"https://api.github.com/users/kripken/gists{/gist_id}","starred_url":"https://api.github.com/users/kripken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kripken/subscriptions","organizations_url":"https://api.github.com/users/kripken/orgs","repos_url":"https://api.github.com/users/kripken/repos","events_url":"https://api.github.com/users/kripken/events{/privacy}","received_events_url":"https://api.github.com/users/kripken/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kripken/emscripten","description":"Emscripten: An LLVM-to-JavaScript Compiler","fork":false,"url":"https://api.github.com/repos/kripken/emscripten","forks_url":"https://api.github.com/repos/kripken/emscripten/forks","keys_url":"https://api.github.com/repos/kripken/emscripten/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kripken/emscripten/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kripken/emscripten/teams","hooks_url":"https://api.github.com/repos/kripken/emscripten/hooks","issue_events_url":"https://api.github.com/repos/kripken/emscripten/issues/events{/number}","events_url":"https://api.github.com/repos/kripken/emscripten/events","assignees_url":"https://api.github.com/repos/kripken/emscripten/assignees{/user}","branches_url":"https://api.github.com/repos/kripken/emscripten/branches{/branch}","tags_url":"https://api.github.com/repos/kripken/emscripten/tags","blobs_url":"https://api.github.com/repos/kripken/emscripten/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kripken/emscripten/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kripken/emscripten/git/refs{/sha}","trees_url":"https://api.github.com/repos/kripken/emscripten/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kripken/emscripten/statuses/{sha}","languages_url":"https://api.github.com/repos/kripken/emscripten/languages","stargazers_url":"https://api.github.com/repos/kripken/emscripten/stargazers","contributors_url":"https://api.github.com/repos/kripken/emscripten/contributors","subscribers_url":"https://api.github.com/repos/kripken/emscripten/subscribers","subscription_url":"https://api.github.com/repos/kripken/emscripten/subscription","commits_url":"https://api.github.com/repos/kripken/emscripten/commits{/sha}","git_commits_url":"https://api.github.com/repos/kripken/emscripten/git/commits{/sha}","comments_url":"https://api.github.com/repos/kripken/emscripten/comments{/number}","issue_comment_url":"https://api.github.com/repos/kripken/emscripten/issues/comments{/number}","contents_url":"https://api.github.com/repos/kripken/emscripten/contents/{+path}","compare_url":"https://api.github.com/repos/kripken/emscripten/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kripken/emscripten/merges","archive_url":"https://api.github.com/repos/kripken/emscripten/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kripken/emscripten/downloads","issues_url":"https://api.github.com/repos/kripken/emscripten/issues{/number}","pulls_url":"https://api.github.com/repos/kripken/emscripten/pulls{/number}","milestones_url":"https://api.github.com/repos/kripken/emscripten/milestones{/number}","notifications_url":"https://api.github.com/repos/kripken/emscripten/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kripken/emscripten/labels{/name}","releases_url":"https://api.github.com/repos/kripken/emscripten/releases{/id}","created_at":"2011-02-12T05:23:30Z","updated_at":"2015-06-10T01:11:52Z","pushed_at":"2015-06-10T01:17:34Z","git_url":"git://github.com/kripken/emscripten.git","ssh_url":"git@github.com:kripken/emscripten.git","clone_url":"https://github.com/kripken/emscripten.git","svn_url":"https://github.com/kripken/emscripten","homepage":"","size":241589,"stargazers_count":8388,"watchers_count":8388,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":970,"mirror_url":null,"open_issues_count":601,"forks":970,"open_issues":601,"watchers":8388,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/3326"},"html":{"href":"https://github.com/kripken/emscripten/pull/3326"},"issue":{"href":"https://api.github.com/repos/kripken/emscripten/issues/3326"},"comments":{"href":"https://api.github.com/repos/kripken/emscripten/issues/3326/comments"},"review_comments":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/3326/comments"},"review_comment":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/3326/commits"},"statuses":{"href":"https://api.github.com/repos/kripken/emscripten/statuses/3a7c14bc19381e35a70b67c12d815967a798ff44"}}}}