{"action":"opened","issue":{"url":"https://api.github.com/repos/marijnh/acorn/issues/268","labels_url":"https://api.github.com/repos/marijnh/acorn/issues/268/labels{/name}","comments_url":"https://api.github.com/repos/marijnh/acorn/issues/268/comments","events_url":"https://api.github.com/repos/marijnh/acorn/issues/268/events","html_url":"https://github.com/marijnh/acorn/issues/268","id":85305658,"number":268,"title":"Normailzation of `\\r` in template literal to `\\n` not working","user":{"login":"getify","id":150330,"avatar_url":"https://avatars.githubusercontent.com/u/150330?v=3","gravatar_id":"","url":"https://api.github.com/users/getify","html_url":"https://github.com/getify","followers_url":"https://api.github.com/users/getify/followers","following_url":"https://api.github.com/users/getify/following{/other_user}","gists_url":"https://api.github.com/users/getify/gists{/gist_id}","starred_url":"https://api.github.com/users/getify/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/getify/subscriptions","organizations_url":"https://api.github.com/users/getify/orgs","repos_url":"https://api.github.com/users/getify/repos","events_url":"https://api.github.com/users/getify/events{/privacy}","received_events_url":"https://api.github.com/users/getify/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-06-04T22:28:32Z","updated_at":"2015-06-04T22:28:32Z","closed_at":null,"body":"```js\r\nvar acorn = require(\"acorn\");\r\nvar a = acorn.parse(\"`x\\ry`;\",{ ecmaVersion: 6 });\r\nconsole.log(JSON.stringify(a,null,\"  \"));\r\n```\r\n\r\nProduces:\r\n\r\n```js\r\n{\r\n  \"start\": 0,\r\n  \"body\": [\r\n    {\r\n      \"start\": 0,\r\n      \"expression\": {\r\n        \"start\": 0,\r\n        \"expressions\": [],\r\n        \"quasis\": [\r\n          {\r\n            \"start\": 1,\r\n            \"value\": {\r\n              \"raw\": \"x\\ry\",\r\n              \"cooked\": \"x\\ry\"\r\n            },\r\n            \"tail\": true,\r\n            \"type\": \"TemplateElement\",\r\n            \"end\": 4\r\n          }\r\n        ],\r\n        \"type\": \"TemplateLiteral\",\r\n        \"end\": 5\r\n      },\r\n      \"type\": \"ExpressionStatement\",\r\n      \"end\": 6\r\n    }\r\n  ],\r\n  \"sourceType\": \"script\",\r\n  \"type\": \"Program\",\r\n  \"end\": 6\r\n}\r\n```\r\n\r\nNotice the `\\r`'s instead of `\\n`'s.\r\n\r\n**Note:** I don't how this will map to the `raw` property of the AST, but the spec even calls for this normalization to happen for the template literal `raw` value (that is, there's no way to get the `\\r` once the literal is processed). Would seem like the AST should be the same, but I'm not sure if that kind of stuff is parser-level or later."}}