[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-19 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin added a comment. It looks like there is no support for the proposed solution so I found alternative solution that might be even better. We can use double quotation `"` for multiline strings. It solves problem because in case of double quotation LLVM escapes new line like `\n` so

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-18 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin added a comment. @njames93 - friendly ping, could you please take another look. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 ___ cfe-commits m

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-16 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 271232. DmitryPolukhin added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 Files: clang/include/clang/Tooling/ReplacementsYaml.h llvm/lib

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-12 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 270351. DmitryPolukhin added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 Files: clang/include/clang/Tooling/ReplacementsYaml.h llvm/lib

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-11 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 270206. DmitryPolukhin added a comment. Fix single new line handling, it should be replace with space Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 Files: cl

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-05 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 268737. DmitryPolukhin marked 2 inline comments as done. DmitryPolukhin added a comment. Fix spelling Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 Files: cl

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-05 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 268736. DmitryPolukhin marked an inline comment as done. DmitryPolukhin added a comment. Rewrite input string split too Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-05 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin added inline comments. Comment at: llvm/lib/Support/YAMLTraits.cpp:894 + std::string &Val) { + Val.clear(); + size_t CurrentPos = 0; njames93 wrote: > If you want to do the same here... > ``` > SmallVec

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-04 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: llvm/lib/Support/YAMLTraits.cpp:894 + std::string &Val) { + Val.clear(); + size_t CurrentPos = 0; If you want to do the same here... ``` SmallVector Lines; Scalar.split(Li

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-04 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 268583. DmitryPolukhin added a comment. Apply suggested changes with string split Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 Files: clang/include/clang/To

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-02 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added inline comments. Comment at: llvm/lib/Support/YAMLTraits.cpp:904 + std::string &Val) { + Val.clear(); + size_t CurrentPos = 0; DmitryPolukhin wrote: > mgehre wrote: > > I wonder whether using StringRef::spl

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-06-02 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin added reviewers: Eugene.Zelenko, thegameg. DmitryPolukhin marked an inline comment as done. DmitryPolukhin added subscribers: thegameg, Eugene.Zelenko. DmitryPolukhin added a comment. + @gribozavr, @Eugene.Zelenko, @thegameg who touched/reviewed this code, please take a look. ==

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-05-21 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added a comment. Thanks for doing this! I didn't work on the YAML parser before, so I cannot give formal approval. Comment at: llvm/lib/Support/YAMLTraits.cpp:904 + std::string &Val) { + Val.clear(); + size_t CurrentPos = 0; -

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-05-20 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 265329. DmitryPolukhin added a comment. Fixed second string after new line + more test case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 Files: clang/includ

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-05-20 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 265292. DmitryPolukhin added a comment. Fix clang-tidy warnings Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80301/new/ https://reviews.llvm.org/D80301 Files: clang/include/clang/Tooling/Replacements

[PATCH] D80301: [yaml][clang-tidy] Fix new line YAML serialization

2020-05-20 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin created this revision. DmitryPolukhin added reviewers: gribozavr, mgehre, yvvan. DmitryPolukhin added projects: clang-tools-extra, clang. Herald added subscribers: hiraditya, xazax.hun. Herald added a project: LLVM. DmitryPolukhin edited the summary of this revision. Move new line d