The before and after selectors allow users to specify a zero-length range -- a point -- at the relevant location in an AST-node's source. Point ranges can be useful, for example, to insert a change using an API that takes a range to be modified (e.g. tooling::change()).
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
LGTM!
clang/lib/Tooling/Refactoring/RangeSelector.cpp | ||
---|---|---|
124 ↗ | (On Diff #201315) | Ah, we're so lucky to have the source manager here! |
clang/unittests/Tooling/RangeSelectorTest.cpp | ||
130 ↗ | (On Diff #201315) | NIT: Consider using llvm::Annotations from llvm/Testing/Support, they might help to produce more readable tests. No need to change anything in this revision, obviously. |