ilya-biryukov accepted this revision.
ilya-biryukov added a comment.
This revision is now accepted and ready to land.
LGTM.
`getExtendedRange` is a really good choice!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D58556/new/
https://reviews.llvm.or
ilya-biryukov added a comment.
Ignore my previous comment, I'll take another look
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D58556/new/
https://reviews.llvm.org/D58556
___
cfe-commits mailing list
c
ilya-biryukov added a comment.
Ah, had some comments and forgot to send them out before I went on vacation :-(
Comment at: clang/include/clang/Tooling/FixIt.h:60
+// future to include more associated text (like comments).
+CharSourceRange getSourceRangeAuto(const Stmt &S, ASTCo
ymandel updated this revision to Diff 190039.
ymandel marked an inline comment as done.
ymandel edited the summary of this revision.
ymandel added a comment.
Remove unneeded includes.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D58556/new/
https:/
ymandel marked 7 inline comments as done.
ymandel added inline comments.
Comment at: clang/include/clang/Tooling/FixIt.h:73
+// context. In contrast with \p getText(), this function selects a source range
+// "automatically", extracting text that a reader might intuitively associ
ymandel updated this revision to Diff 190037.
ymandel marked an inline comment as done.
ymandel edited the summary of this revision.
ymandel added a comment.
This update significantly simplifies the change. It removes any "smarts",
instead allowing the user to request the extension of the source
kimgr added inline comments.
Comment at: clang/include/clang/Tooling/FixIt.h:73
+// context. In contrast with \p getText(), this function selects a source range
+// "automatically", extracting text that a reader might intuitively associate
+// with a node. Currently, only specia
ymandel marked 5 inline comments as done.
ymandel added inline comments.
Comment at: clang/include/clang/Tooling/FixIt.h:73
+// context. In contrast with \p getText(), this function selects a source range
+// "automatically", extracting text that a reader might intuitively associ
kimgr added inline comments.
Comment at: clang/include/clang/Tooling/FixIt.h:73
+// context. In contrast with \p getText(), this function selects a source range
+// "automatically", extracting text that a reader might intuitively associate
+// with a node. Currently, only specia
ymandel marked 4 inline comments as done.
ymandel added inline comments.
Comment at: clang/include/clang/Tooling/FixIt.h:60
+// future to include more associated text (like comments).
+CharSourceRange getSourceRangeAuto(const Stmt &S, ASTContext &Context);
+
ilya
ilya-biryukov added a comment.
Thanks, the APIs totally make sense. And seem to fit into the other functions
we have in `FixIt.h`, although the name of the file is somewhat misleading.
Mostly comments about naming and one comment about the necessity of using
matchers from my side.
===
ymandel created this revision.
ymandel added a reviewer: ilya-biryukov.
ymandel added a project: clang.
Herald added a subscriber: jdoerfert.
Introduces variants of `getText` and `getSourceRange` that extract the source
text of an AST node based on contextual considerations. This revision
intro
12 matches
Mail list logo