{"action":"created","issue":{"url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/4338","labels_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/4338/labels{/name}","comments_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/4338/comments","events_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/4338/events","html_url":"https://github.com/D-Programming-Language/dmd/pull/4338","id":55422159,"number":4338,"title":"Issue 9731: implement $(DDOC_PARAGRAPH)","user":{"login":"quickfur","id":405446,"avatar_url":"https://avatars.githubusercontent.com/u/405446?v=3","gravatar_id":"","url":"https://api.github.com/users/quickfur","html_url":"https://github.com/quickfur","followers_url":"https://api.github.com/users/quickfur/followers","following_url":"https://api.github.com/users/quickfur/following{/other_user}","gists_url":"https://api.github.com/users/quickfur/gists{/gist_id}","starred_url":"https://api.github.com/users/quickfur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/quickfur/subscriptions","organizations_url":"https://api.github.com/users/quickfur/orgs","repos_url":"https://api.github.com/users/quickfur/repos","events_url":"https://api.github.com/users/quickfur/events{/privacy}","received_events_url":"https://api.github.com/users/quickfur/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-01-25T17:17:26Z","updated_at":"2015-01-25T17:30:06Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/4338","html_url":"https://github.com/D-Programming-Language/dmd/pull/4338","diff_url":"https://github.com/D-Programming-Language/dmd/pull/4338.diff","patch_url":"https://github.com/D-Programming-Language/dmd/pull/4338.patch"},"body":"Fixes: https://issues.dlang.org/show_bug.cgi?id=9731\r\n\r\nBasically, this will wrap text within ddoc comments into proper paragraphs (via a new macro `DDOC_PARAGRAPH`) so that ddoc output can produce correctly-nested paragraph tags in strict output formats like XHTML or DOCBOOK.\r\n\r\nFor backward compatibility, `DDOC_PARAGRAPH` defaults to just `$0`, and `DDOC_BLANKLINE` retains its old behaviour. The expected usage pattern, however, is to define `DDOC_BLANKLINE` and `BR` to be blank, and `DDOC_PARAGRAPH` to be `<p>$0</p>` (or equivalent).\r\n\r\nThe testcase uses contrived tags for `DDOC_PARAGRAPH` and `BR` in order to verify that the generated paragraph tags came from `DDOC_PARAGRAPH` (not something else that expands to `<p>`), and that the `$(BR)` macros are generated in backward-compatible locations."},"comment":{"url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/comments/71382314","html_url":"https://github.com/D-Programming-Language/dmd/pull/4338#issuecomment-71382314","issue_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/4338","id":71382314,"user":{"login":"andralex","id":566679,"avatar_url":"https://avatars.githubusercontent.com/u/566679?v=3","gravatar_id":"","url":"https://api.github.com/users/andralex","html_url":"https://github.com/andralex","followers_url":"https://api.github.com/users/andralex/followers","following_url":"https://api.github.com/users/andralex/following{/other_user}","gists_url":"https://api.github.com/users/andralex/gists{/gist_id}","starred_url":"https://api.github.com/users/andralex/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andralex/subscriptions","organizations_url":"https://api.github.com/users/andralex/orgs","repos_url":"https://api.github.com/users/andralex/repos","events_url":"https://api.github.com/users/andralex/events{/privacy}","received_events_url":"https://api.github.com/users/andralex/received_events","type":"User","site_admin":false},"created_at":"2015-01-25T17:30:06Z","updated_at":"2015-01-25T17:30:06Z","body":"Thinking about it a bit more I guess it's fine if we leave other whitespace be. I'd say any run of `\\n` containing at least two should be considered one paragraph break. "}}