[clang-doc] Fix paths of js in import tags
HTML requires posix-style paths. Differential Revision: https://reviews.llvm.org/D65827 llvm-svn: 368087
This commit is contained in:
parent
e1f4c4aad2
commit
40fde90193
|
@ -256,6 +256,8 @@ genJsScriptsHTML(StringRef InfoPath, const ClangDocContext &CDCtx) {
|
|||
auto ScriptNode = llvm::make_unique<TagNode>(HTMLTag::TAG_SCRIPT);
|
||||
SmallString<128> ScriptPath = computeRelativePath("", InfoPath);
|
||||
llvm::sys::path::append(ScriptPath, llvm::sys::path::filename(FilePath));
|
||||
// Paths in HTML must be in posix-style
|
||||
llvm::sys::path::native(ScriptPath, llvm::sys::path::Style::posix);
|
||||
ScriptNode->Attributes.try_emplace("src", ScriptPath);
|
||||
Out.emplace_back(std::move(ScriptNode));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue