Skip to content

Fix inconsistency between JSON output and ddoc output#6621

Merged
andralex merged 1 commit intodlang:masterfrom
yshui:jsonddoc
Oct 30, 2017
Merged

Fix inconsistency between JSON output and ddoc output#6621
andralex merged 1 commit intodlang:masterfrom
yshui:jsonddoc

Conversation

@yshui
Copy link
Copy Markdown
Contributor

@yshui yshui commented Mar 11, 2017

JSON should include version blocks in templates, same as ddoc.

BTW, I think we should include both branches of static if in ddoc output.

@yshui
Copy link
Copy Markdown
Contributor Author

yshui commented Mar 11, 2017

This fixes dlang/ddox#86.

Forum discussion

@yshui
Copy link
Copy Markdown
Contributor Author

yshui commented Mar 12, 2017

Oops, huge change in the resulting documents....

How can I see the diffs?

@yshui
Copy link
Copy Markdown
Contributor Author

yshui commented Mar 12, 2017

Somehow ddox associate the document to member of the template, not the template itself. Does anybody know why?

@WalterBright
Copy link
Copy Markdown
Member

Since this is fixing a bug, can you please file a bugzilla issue for it? That will make the changelog easier and more organized. Thanks!

@dlang-bot
Copy link
Copy Markdown
Contributor

dlang-bot commented Mar 14, 2017

Thanks for your pull request, @yshui! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.

Some tips to help speed things up:

  • smaller, focused PRs are easier to review than big ones

  • try not to mix up refactoring or style changes with bug fixes or feature enhancements

  • provide helpful commit messages explaining the rationale behind each change

Bear in mind that large or tricky changes may require multiple rounds of review and revision.

Please see CONTRIBUTING.md for more information.

Bugzilla references

Auto-close Bugzilla Description
17256 Inconsistent output between json and ddoc

@yshui
Copy link
Copy Markdown
Contributor Author

yshui commented Mar 14, 2017

@WalterBright But this change also has big impact on the ddox output. Can you review the change?

@MartinNowak MartinNowak self-assigned this Mar 15, 2017
@MartinNowak
Copy link
Copy Markdown
Member

MartinNowak commented Mar 15, 2017

We do have tests for the JSON output, simply add to that.
https://github.com/dlang/dmd/blob/master/test/compilable/json.d
https://github.com/dlang/dmd/blob/master/test/compilable/extra-files/json.out

We can then separaretly check ddox whether it correctly processes those entities.

@andralex
Copy link
Copy Markdown
Member

cc @yshui there seem to be errors in the autotester, please check so we move this forward?

JSON should include version blocks in templates, same as ddoc.
@yshui
Copy link
Copy Markdown
Contributor Author

yshui commented Oct 30, 2017

Seems DAutoTest can't find libdparse?

@andralex
Copy link
Copy Markdown
Member

cc @MartinNowak

@andralex andralex merged commit 1eb3de2 into dlang:master Oct 30, 2017
@schveiguy
Copy link
Copy Markdown
Member

Digger says this caused a regression: https://issues.dlang.org/show_bug.cgi?id=20742

It appears the json output is now putting out MORE than what ddoc puts out, including docs inside a version(none) block. I'll look into how we can make these two systems match.

MoonlightSentinel added a commit to MoonlightSentinel/dmd that referenced this pull request Apr 17, 2020
MoonlightSentinel added a commit to MoonlightSentinel/dmd that referenced this pull request Apr 17, 2020
PR dlang#6621 took the code for pending `ConditionalDeclaration`s from
doc.d but missed the early return.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants