mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-05 13:08:58 +00:00
Output multiline doc comments over multiple lines
Tested: on Linux Bug: 15779934 Change-Id: I6f822f1705e443d8721ea208dcb021aad3c8715c
This commit is contained in:
@@ -38,11 +38,13 @@ std::string MakeCamel(const std::string &in, bool first) {
|
||||
}
|
||||
|
||||
// Generate a documentation comment, if available.
|
||||
void GenComment(const std::string &dc, std::string *code_ptr,
|
||||
void GenComment(const std::vector<std::string> &dc, std::string *code_ptr,
|
||||
const char *prefix) {
|
||||
std::string &code = *code_ptr;
|
||||
if (dc.length()) {
|
||||
code += std::string(prefix) + "///" + dc + "\n";
|
||||
for (auto it = dc.begin();
|
||||
it != dc.end();
|
||||
++it) {
|
||||
code += std::string(prefix) + "///" + *it + "\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user