{"action":"created","issue":{"url":"https://api.github.com/repos/jruby/jruby/issues/4172","repository_url":"https://api.github.com/repos/jruby/jruby","labels_url":"https://api.github.com/repos/jruby/jruby/issues/4172/labels{/name}","comments_url":"https://api.github.com/repos/jruby/jruby/issues/4172/comments","events_url":"https://api.github.com/repos/jruby/jruby/issues/4172/events","html_url":"https://github.com/jruby/jruby/issues/4172","id":178792569,"number":4172,"title":"A DStrNode is generated when parsing squigly heredocs","user":{"login":"jsyeo","id":1090020,"avatar_url":"https://avatars.githubusercontent.com/u/1090020?v=3","gravatar_id":"","url":"https://api.github.com/users/jsyeo","html_url":"https://github.com/jsyeo","followers_url":"https://api.github.com/users/jsyeo/followers","following_url":"https://api.github.com/users/jsyeo/following{/other_user}","gists_url":"https://api.github.com/users/jsyeo/gists{/gist_id}","starred_url":"https://api.github.com/users/jsyeo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsyeo/subscriptions","organizations_url":"https://api.github.com/users/jsyeo/orgs","repos_url":"https://api.github.com/users/jsyeo/repos","events_url":"https://api.github.com/users/jsyeo/events{/privacy}","received_events_url":"https://api.github.com/users/jsyeo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":8,"created_at":"2016-09-23T06:06:13Z","updated_at":"2016-09-26T16:55:12Z","closed_at":null,"body":"When parsing squigly heredocs, a `DStrNode` is produced if there are spaces between the first heredoc line and the content. Like for example: `\"<<~TEST\\n hello\\nTEST\"`. If I try to parse it without any spaces, only the `StrNode` is produced.\r\n\r\n```\r\n[23] pry(main)> parse(\"<<~TEST\\nhello\\nTEST\").map { |a| a }\r\n=> [#<Java::OrgJrubyparserAst::RootNode:0x33617539>, #<Java::OrgJrubyparserAst::StrNode:0x5db4c359>]\r\n[24] pry(main)> parse(\"<<~TEST\\n hello\\nTEST\").map { |a| a }\r\n=> [#<Java::OrgJrubyparserAst::RootNode:0x7997b197>,\r\n #<Java::OrgJrubyparserAst::DStrNode:0x460f76a6>,\r\n #<Java::OrgJrubyparserAst::StrNode:0x11acdc30>,\r\n #<Java::OrgJrubyparserAst::StrNode:0x4a8ab068>]\r\n```\r\n\r\n### Environment\r\n\r\n```\r\n» jruby --version\r\njruby 9.1.5.0 (2.3.1) 2016-09-07 036ce39 Java HotSpot(TM) 64-Bit Server VM 25.102-b14 on 1.8.0_102-b14 +jit [darwin-x86_64]\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/jruby/jruby/issues/comments/249629079","html_url":"https://github.com/jruby/jruby/issues/4172#issuecomment-249629079","issue_url":"https://api.github.com/repos/jruby/jruby/issues/4172","id":249629079,"user":{"login":"headius","id":10135,"avatar_url":"https://avatars.githubusercontent.com/u/10135?v=3","gravatar_id":"","url":"https://api.github.com/users/headius","html_url":"https://github.com/headius","followers_url":"https://api.github.com/users/headius/followers","following_url":"https://api.github.com/users/headius/following{/other_user}","gists_url":"https://api.github.com/users/headius/gists{/gist_id}","starred_url":"https://api.github.com/users/headius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/headius/subscriptions","organizations_url":"https://api.github.com/users/headius/orgs","repos_url":"https://api.github.com/users/headius/repos","events_url":"https://api.github.com/users/headius/events{/privacy}","received_events_url":"https://api.github.com/users/headius/received_events","type":"User","site_admin":false},"created_at":"2016-09-26T16:55:12Z","updated_at":"2016-09-26T16:55:12Z","body":"Perhaps this issue should be moved to jruby/jruby-parser, since for standard JRuby uses, nobody will ever see that this is a DStr?"}}
{"actor":{"display_login":"headius"}}