{"action":"closed","issue":{"url":"https://api.github.com/repos/chriseth/browser-solidity/issues/92","repository_url":"https://api.github.com/repos/chriseth/browser-solidity","labels_url":"https://api.github.com/repos/chriseth/browser-solidity/issues/92/labels{/name}","comments_url":"https://api.github.com/repos/chriseth/browser-solidity/issues/92/comments","events_url":"https://api.github.com/repos/chriseth/browser-solidity/issues/92/events","html_url":"https://github.com/chriseth/browser-solidity/issues/92","id":129877071,"number":92,"title":"solc.compile hanging inexplicably on specific, legal, function signature","user":{"login":"aaronstjohn","id":16142314,"avatar_url":"https://avatars.githubusercontent.com/u/16142314?v=3","gravatar_id":"","url":"https://api.github.com/users/aaronstjohn","html_url":"https://github.com/aaronstjohn","followers_url":"https://api.github.com/users/aaronstjohn/followers","following_url":"https://api.github.com/users/aaronstjohn/following{/other_user}","gists_url":"https://api.github.com/users/aaronstjohn/gists{/gist_id}","starred_url":"https://api.github.com/users/aaronstjohn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aaronstjohn/subscriptions","organizations_url":"https://api.github.com/users/aaronstjohn/orgs","repos_url":"https://api.github.com/users/aaronstjohn/repos","events_url":"https://api.github.com/users/aaronstjohn/events{/privacy}","received_events_url":"https://api.github.com/users/aaronstjohn/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-01-29T20:42:29Z","updated_at":"2016-04-15T18:41:52Z","closed_at":"2016-04-15T18:41:52Z","body":"I've found that calls to solc.compile are hanging on contracts with very specific signatures. \r\n\r\n\r\nnote: I'm using solc version 0.2.0-1. \r\n\r\nThe following contract:\r\n```\r\ncontract TwoStringInternal{\r\n\r\n\tfunction twoString1(string str1, string str2)  internal  \r\n\t{\r\n\t\t\r\n\t}\r\n}\r\n```\r\nCauses  solc.compile to hang indefinitely when supplied as input.\r\n\r\nYet, with the slight adjustment:\r\n```\r\ncontract TwoStringInternal{\r\n\t//\t\tI Added another character here\r\n\t//\t\t\t       V\r\n\tfunction twoString12(string str1, string str2)  internal  \r\n\t{\r\n\t\t\r\n\t}\r\n}\r\n```\r\nThe same exact call to solc.compile works perfectly fine.\r\n\r\nSimilarly, I've found that doing any of the following adjustments to the first code segment will cause solc.compile to exit with no problems.\r\n\r\n1.  Adding additional characters to the function's name\r\n2.  Removing a string argument\r\n3.  Removing the 'internal' access modifier.\r\n\r\nIt's baffling to me why this specific signature, puts solc.compile into an infinite hang.\r\n\r\nI've been running the compiler via node directly (see code below). The very same code works fine using the browser editor.\r\n\r\nFor reference, this is the code I'm using to compile:\r\n```\r\nvar solc = require('solc');\r\nvar fs = require(\"fs\");\r\nvar input = {};\r\n\r\n//input['TwoStringInternalCompiles'] = fs.readFileSync(\"./TwoStringInternal_compiles.sol\", {encoding: \"utf8\"});\r\ninput['TwoStringInternalDoesntCompile'] = fs.readFileSync(\"./TwoStringInternal_doesnt_compile.sol\", {encoding: \"utf8\"});\r\n\r\n//console.log(\"Compiling code: \"+input['TwoStringInternalCompiles']);\r\nconsole.log(\"Compiling code: \"+input['TwoStringInternalDoesntCompile']);\r\n\r\nvar output = solc.compile({sources: input}, 1);\r\nconsole.log(\"Compilation completed\");\r\nfor (var contractName in output.contracts)\r\n   console.log(contractName + ': ' + output.contracts[contractName].bytecode);\r\n```\r\n\r\n\r\n\r\n"}}