[clang-doc] Generate HTML links for children namespaces/records
authorDiego Astiazaran <diegoaat97@gmail.com>
Mon, 12 Aug 2019 18:42:46 +0000 (18:42 +0000)
committerDiego Astiazaran <diegoaat97@gmail.com>
Mon, 12 Aug 2019 18:42:46 +0000 (18:42 +0000)
commite27f778a1992177cdd19130a7148dab9e343b747
tree8945e3e998ed450a2e4c47cb4a659e9e526f8055
parentc9f476a503b5a8b053475ee6ae125814fd928342
[clang-doc] Generate HTML links for children namespaces/records

Path is now stored in the references to the child while serializing,
then this path is used to generate the relative path in the HTML
generator.
Now some references have paths and some don't so in the reducing phase,
references are now properly merged checking for empty attributes.
Tests added for HTML and YAML generators, merging and serializing.
computeRelativePath function had a bug when the filepath is part of the
given directory; it returned a path that starts with a separator. This
has been fixed.

Differential Revision: https://reviews.llvm.org/D65987

llvm-svn: 368602
clang-tools-extra/clang-doc/HTMLGenerator.cpp
clang-tools-extra/clang-doc/Representation.cpp
clang-tools-extra/clang-doc/Representation.h
clang-tools-extra/clang-doc/Serialize.cpp
clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp
clang-tools-extra/unittests/clang-doc/MergeTest.cpp
clang-tools-extra/unittests/clang-doc/SerializeTest.cpp
clang-tools-extra/unittests/clang-doc/YAMLGeneratorTest.cpp