{"action":"created","issue":{"url":"https://api.github.com/repos/acornjs/acorn/issues/691","repository_url":"https://api.github.com/repos/acornjs/acorn","labels_url":"https://api.github.com/repos/acornjs/acorn/issues/691/labels{/name}","comments_url":"https://api.github.com/repos/acornjs/acorn/issues/691/comments","events_url":"https://api.github.com/repos/acornjs/acorn/issues/691/events","html_url":"https://github.com/acornjs/acorn/issues/691","id":310233357,"node_id":"MDU6SXNzdWUzMTAyMzMzNTc=","number":691,"title":"Feature Request : On parsing error, warn about possibility of a runaway backtick (template) string","user":{"login":"aavmurphy","id":5877681,"node_id":"MDQ6VXNlcjU4Nzc2ODE=","avatar_url":"https://avatars2.githubusercontent.com/u/5877681?v=4","gravatar_id":"","url":"https://api.github.com/users/aavmurphy","html_url":"https://github.com/aavmurphy","followers_url":"https://api.github.com/users/aavmurphy/followers","following_url":"https://api.github.com/users/aavmurphy/following{/other_user}","gists_url":"https://api.github.com/users/aavmurphy/gists{/gist_id}","starred_url":"https://api.github.com/users/aavmurphy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aavmurphy/subscriptions","organizations_url":"https://api.github.com/users/aavmurphy/orgs","repos_url":"https://api.github.com/users/aavmurphy/repos","events_url":"https://api.github.com/users/aavmurphy/events{/privacy}","received_events_url":"https://api.github.com/users/aavmurphy/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-03-31T11:17:04Z","updated_at":"2018-06-09T08:03:02Z","closed_at":null,"author_association":"NONE","body":"When there is a parsing error, warn about the possibility of a runaway (backtick) literal template.\r\n\r\nI had done\r\n\r\n```\r\nconsole.info(  ` literal string wrongly terminated by a single quote' );\r\n... many lines of code later ... \r\n... which are passed as part of the template ...\r\nconsole.info(  `another literal template, which closes the earlier backtick, and then which throws a  parsing error at \"another\" ` );\r\n```\r\n\r\ncurrent error\r\n```\r\nerror  Parsing error: Unexpected token another at line [another's line no.]\r\n```\r\nchange to \r\n```\r\nerror  Parsing error: Unexpected token another - could be a runaway ` (backtick) template starting at line [literal string start line number]\r\n```\r\n\r\n**Tell us about your environment**\r\neslint v4.19.1 (which uses acron)\r\n\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/acornjs/acorn/issues/comments/395949725","html_url":"https://github.com/acornjs/acorn/issues/691#issuecomment-395949725","issue_url":"https://api.github.com/repos/acornjs/acorn/issues/691","id":395949725,"node_id":"MDEyOklzc3VlQ29tbWVudDM5NTk0OTcyNQ==","user":{"login":"ghaiklor","id":3625244,"node_id":"MDQ6VXNlcjM2MjUyNDQ=","avatar_url":"https://avatars0.githubusercontent.com/u/3625244?v=4","gravatar_id":"","url":"https://api.github.com/users/ghaiklor","html_url":"https://github.com/ghaiklor","followers_url":"https://api.github.com/users/ghaiklor/followers","following_url":"https://api.github.com/users/ghaiklor/following{/other_user}","gists_url":"https://api.github.com/users/ghaiklor/gists{/gist_id}","starred_url":"https://api.github.com/users/ghaiklor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ghaiklor/subscriptions","organizations_url":"https://api.github.com/users/ghaiklor/orgs","repos_url":"https://api.github.com/users/ghaiklor/repos","events_url":"https://api.github.com/users/ghaiklor/events{/privacy}","received_events_url":"https://api.github.com/users/ghaiklor/received_events","type":"User","site_admin":false},"created_at":"2018-06-09T08:03:02Z","updated_at":"2018-06-09T08:03:02Z","author_association":"CONTRIBUTOR","body":"I'm not sure is possible. What if you'd want to insert some code snippet into your string ?\r\n\r\nExample:\r\n\r\n```js\r\nconsole.info(`\r\n// You can make something by calling something, bla bla...\r\n// here some code\r\nconst foo = 'bar';\r\nconst bar = 'baz';\r\n\r\nfunction someFunctionsHere() {}\r\n\r\n// And all of it is a must be in template string, because is that what you want to print.\r\n`);\r\n```\r\n\r\nHow can we detect the fact of runaway backtick, any ideas ?"}}
{"actor":{"display_login":"ghaiklor"}}